() |
#
# Purpose : This file provides an example of a call to the
# function res_display_anim_setup_2d()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Linear Ramp variation is
# set for subsequent animation. Then this
# function is called to set the number of
# frames to be 30 with linear interpolation.
# The animation is started in the end.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_anim_setup_2d()
# has the following arguments:
#
# res_display_anim_setup_2d
# ( number_frames,
# interp_method,
# file_name )
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_number_frames
STRING s_interp_method[32]
STRING s_file_name[32]
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Use Linear Ramp variation for subsequent animation
i_return_value = res_display_tool_animate_scale ( "Ramp", @
"Deformation", "", 0.0 )
dump i_return_value
#---------------------------------------------------------------------
# Specify number of frames and interpolation for 2D image animation
i_number_frames = 30
s_interp_method = "Linear"
s_file_name = ""
i_return_value = @
res_display_anim_setup_2d @
( i_number_frames, @
s_interp_method, @
s_file_name )
dump i_return_value
# Start running animation with delay of 10 milli-seconds per frame
i_return_value = res_display_anim_run( 10 )
dump i_return_value
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of a call to the
# function res_display_anim_setup_3d()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Linear Ramp variation is
# set for subsequent animation. Then this
# function is called to set the number of
# frames to be 30 with "Closest" value for
# frames. The animation is started in the end.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_anim_setup_3d()
# has the following arguments:
#
# res_display_anim_setup_3d
# ( number_frames,
# interp_method )
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_number_frames
STRING s_interp_method[32]
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Use Linear Ramp variation for subsequent animation
i_return_value = res_display_tool_animate_scale ( "Ramp", @
"Deformation", "", 0.0 )
dump i_return_value
#---------------------------------------------------------------------
# Specify number of frames and interpolation for 3D image animation
i_number_frames = 30
s_interp_method = "Closest"
i_return_value = @
res_display_anim_setup_3d @
( i_number_frames, @
s_interp_method )
dump i_return_value
# Start running animation with delay of 10 milli-seconds per frame
i_return_value = res_display_anim_run( 10 )
dump i_return_value
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of a call to the
# function res_display_anim_image_create()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Parameters like method of
# variation, interpolation and number of frames
# are set and animation is started. Then
# animation is stopped and this function is
# called to create the image file of the
# current frame.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar
#
# The function res_display_anim_image_create()
# has the following arguments:
#
# res_display_anim_image_create
# ( file_name )
#
#---------------------------------------------------------------------
# Variable Declarations
STRING s_file_name[32]
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Set animation parameters and start animation
i_return_value = res_display_tool_animate_scale( "Ramped", @
"Deformation", "", 0. )
dump i_return_value
i_return_value = res_display_anim_setup_2d( 8, "Linear", "")
dump i_return_value
i_return_value = res_display_anim_run( 100 )
dump i_return_value
#---------------------------------------------------------------------
# Stop the running animation and display the next frame in queue.
i_return_value = res_display_anim_step()
dump i_return_value
#---------------------------------------------------------------------
# Create an image file of the current viewport
s_file_name = "IMAGE_FILE.img"
i_return_value = @
res_display_anim_image_create @
( s_file_name )
dump i_return_value
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of a call to the
# function res_display_anim_setup_image()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Parameters like method of
# variation, interpolation and number of frames
# are set and animation is started. Then
# animation is stopped and 10 image files are
# created using function,
# res_display_anim_image_create(). Then this
# function is called to setup the animation
# with the created files.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar
#
# The function res_display_anim_setup_image()
# has the following arguments:
#
# res_display_anim_setup_image
# ( number_frames,
# file_name )
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_number_frames
STRING sa_file_name[32](10)
INTEGER i_return_value
INTEGER i_count
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Set animation parameters and start animation
i_return_value = res_display_tool_animate_scale( "Ramped", @
"Deformation", "", 0. )
dump i_return_value
i_return_value = res_display_anim_setup_2d( 30, "Linear", "")
dump i_return_value
i_return_value = res_display_anim_run( 100 )
dump i_return_value
# Stop animation
i_return_value = res_display_anim_step()
#---------------------------------------------------------------------
# Create 10 image files
FOR ( i_count = 1 TO 10 )
dump i_count
i_return_value = res_display_anim_frame( i_count )
dump i_return_value
sa_file_name(i_count) = "IMAGE.img."//str_from_integer (i_count)
dump sa_file_name(i_count)
i_return_value = res_display_anim_image_create( @
sa_file_name(i_count))
dump i_return_value
END FOR
#---------------------------------------------------------------------
# Set the details of animation frame
i_number_frames = 10
i_return_value = @
res_display_anim_setup_image @
( i_number_frames, @
sa_file_name )
dump i_return_value
# Start animation with modfield frame-set
i_return_value = res_display_anim_run(100)
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of a call to the
# function res_display_anim_bounds()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Parameters like method of
# variation, interpolation and number of frames
# are set and animation is started. After a
# pause this function is called to set the
# bounds of the animation frames.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_anim_bounds()
# has the following arguments:
#
# res_display_anim_bounds
# ( current_frame,
# start_frame,
# end_frame )
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_current_frame
INTEGER i_start_frame
INTEGER i_end_frame
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Set animation parameters and start animation
i_return_value = res_display_tool_animate_scale( "Ramped", @
"Deformation", "", 0. )
dump i_return_value
i_return_value = res_display_anim_setup_2d( 30, "Linear", "" )
dump i_return_value
i_return_value = res_display_anim_run( 10 )
dump i_return_value
#---------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
#---------------------------------------------------------------------
# Set the bounds of frames used by a running animation
i_current_frame = 20
i_start_frame = 15
i_end_frame = 30
i_return_value = @
res_display_anim_bounds @
( i_current_frame, @
i_start_frame, @
i_end_frame )
dump i_return_value
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of a call to the
# function res_display_anim_method()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Parameters like method of
# variation, interpolation and number of frames
# are set and animation is started. After a
# pause this function is called to modify the
# method of paging from "Cycle" to "Bounce".
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_anim_method()
# has the following arguments:
#
# res_display_anim_method
# ( method )
#
#---------------------------------------------------------------------
# Variable Declarations
STRING s_method[16]
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Set animation parameters and start animation
i_return_value = res_display_tool_animate_scale( "Ramped", @
"Deformation", "", 0. )
dump i_return_value
i_return_value = res_display_anim_setup_2d( 30, "Linear", "" )
dump i_return_value
i_return_value = res_display_anim_run( 10 )
dump i_return_value
#---------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
#---------------------------------------------------------------------
# Modify the method of paging from "Cycle" to "Bounce"
s_method = "Bounce"
i_return_value = @
res_display_anim_method @
( s_method )
dump i_return_value
# Note the change in method of animation
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of a call to the
# function res_display_anim_run()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Parameters like method of
# variation, interpolation and number of frames
# are set and animation is started using this
# function. After a pause this function is
# again called to animate with a increased
# delay between frame display.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_anim_run()
# has the following arguments:
#
# res_display_anim_run
# ( delay )
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_delay
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Use Linear Ramp variation for subsequent animation
i_return_value = res_display_tool_animate_scale ( "Ramp", @
"Deformation", "", 0.0 )
dump i_return_value
# Specify number of frames and interpolation for 2D image animation
i_return_value = res_display_anim_setup_2d ( 30, "Linear", "" )
dump i_return_value
#---------------------------------------------------------------------
# Start running animation with delay of 10 milli-seconds per frame
i_delay = 10
i_return_value = @
res_display_anim_run @
( i_delay )
dump i_return_value
#---------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
#---------------------------------------------------------------------
# Start running animation with delay of 10 milli-seconds per frame
i_delay = 100
i_return_value = @
res_display_anim_run @
( i_delay )
dump i_return_value
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of 2 calls to the
# function res_display_anim_step()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Parameters like method of
# variation, interpolation and number of frames
# are set and animation is started. Then this
# function is called twice with a pause
# between each call to load successive frames.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_anim_step() has no arguments.
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Set animation parameters and start animation
i_return_value = res_display_tool_animate_scale( "Ramped", @
"Deformation", "", 0. )
dump i_return_value
i_return_value = res_display_anim_setup_2d( 8, "Linear", "" )
dump i_return_value
i_return_value = res_display_anim_run( 10 )
dump i_return_value
#---------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
#---------------------------------------------------------------------
# Stop the running animation and display the next frame in queue.
i_return_value = res_display_anim_step()
dump i_return_value
#---------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
# Note the change of the deformation plot on the default viewport.
#---------------------------------------------------------------------
# Display the next frame in queue.
i_return_value = res_display_anim_step()
dump i_return_value
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of 2 calls to the
# function res_display_anim_frame()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Parameters like method of
# variation, interpolation and number of frames
# are set and animation is started. Then this
# function is called twice with a pause
# between each call to load 10th and 25th frame.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_anim_frame()
# has the following arguments:
#
# res_display_anim_frame
# ( frame_number )
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_frame_number
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Set animation parameters and start animation
i_return_value = res_display_tool_animate_scale( "Ramped", @
"Deformation", "", 0. )
dump i_return_value
i_return_value = res_display_anim_setup_2d( 30, "Linear", "lourdu" )
dump i_return_value
i_return_value = res_display_anim_run( 10 )
dump i_return_value
#---------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
#---------------------------------------------------------------------
# Stop running animation and display the specified running frame.
i_frame_number = 10
i_return_value = @
res_display_anim_frame @
( i_frame_number )
dump i_return_value
#---------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
# Stop animation
i_return_value = res_display_anim_step()
dump i_return_value
#---------------------------------------------------------------------
# Display the specified running frame.
i_frame_number = 25
i_return_value = @
res_display_anim_frame @
( i_frame_number )
dump i_return_value
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of a call to the
# function res_display_anim_clear()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Parameters like method of
# variation, interpolation and number of frames
# are set and animation is started. After a
# pause this function is called to stop the
# running animation and clear any stored
# animation frames from memory.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_anim_clear() has no arguments.
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Set animation parameters and start animation
i_return_value = res_display_tool_animate_scale( "Ramped", @
"Deformation", "", 0. )
dump i_return_value
i_return_value = res_display_anim_setup_2d( 30, "Linear", "lourdu" )
dump i_return_value
i_return_value = res_display_anim_run( 10 )
dump i_return_value
#---------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
#---------------------------------------------------------------------
# Stop and clear stored animation frames from memory
i_return_value = res_display_anim_clear()
dump i_return_value
# Refresh Graphics
repaint_graphics( )
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of 2 calls to the
# function res_display_anim_active()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. Then this function is
# called before and after animation to check
# whether animation is active or not.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_anim_active() has no arguments.
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_return_value
LOGICAL l_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Query whether animation is active or not
l_return_value = res_display_anim_active()
dump l_return_value
#--------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
#---------------------------------------------------------------------
# Set animation parameters and start animation
i_return_value = res_display_tool_animate_scale( "Ramped", @
"Deformation", "", 0. )
dump i_return_value
i_return_value = res_display_anim_setup_2d( 30, "Linear", "" )
dump i_return_value
i_return_value = res_display_anim_run( 10 )
dump i_return_value
#---------------------------------------------------------------------
# Query whether animation is active or not
l_return_value = res_display_anim_active()
dump l_return_value
#---------------------------------------------------------------------
() |
#
# Purpose : This file provides an example of a call to the
# function res_display_cleanup()
#
# In this example field database, containing
# the results is opened and a Deformation Plot
# tool definition is created & posted in
# default viewport. After a pause this function
# is called to clean the graphical display and
# set graphics to wireframe state.
#
# Before running this file run field.ses to
# create field.db
#
# This file can be run by starting a session of
# Patran,and running this session file
# through the "File","Session","Play" pulldown
# menus on the menu bar.
#
# The function res_display_cleanup() has no arguments.
#
#---------------------------------------------------------------------
# Variable Declarations
INTEGER i_return_value
#---------------------------------------------------------------------
# Open the database ’field.db’
uil_file_open.go ("field.db")
# Set ISO-1 viewing
i_return_value = ga_view_aa_set( 23., -34., 0. )
dump i_return_value
#---------------------------------------------------------------------
# Create & Post Deformation Plot tool
i_return_value = res_data_load_dbresult( 0, "Nodal", "Vector", @
"Default", "Static Subcase", "Displacements", @
"Translational", "(NON-LAYERED)", "", "Global", "", "", "" )
dump i_return_value
i_return_value = res_data_title( 0, "Nodal", "Vector", 1, [ @
"Default, Static Subcase: Displacements, Translational-0"// @
" of 0 layers () "] )
dump i_return_value
i_return_value = res_display_deformation_create( "", "Elements",@
0, [""], 9, [ "DeformedStyle:White,Solid,1,Wireframe", @
"DeformedScale:Model=0.1", "UndeformedStyle:ON,"// @
"Blue,Solid,1,Wireframe", "TitleDisplay:ON", @
"MinMaxDisplay:ON", "ScaleFactor:1.", "LabelStyle:"// @
"Exponential, 12, White, 3", "DeformDisplay:Resultant", @
"DeformComps:OFF,OFF,OFF"] )
dump i_return_value
i_return_value = res_display_deformation_post( "", 0 )
dump i_return_value
#---------------------------------------------------------------------
# Session file paused press "Resume" to continue
sf_pause()
#---------------------------------------------------------------------
# Clean the graphical display and set graphics to wireframe state
i_return_value = res_display_cleanup()
dump i_return_value
#---------------------------------------------------------------------