# ICEM CFD solver interface routine for the manager.
#
# Copyright (c) 1993-1995 ICEM Systems.

proc hp_write_input {} {
    global confname file_name hp_output_path 
    global file_name

    set cart_file $file_name(mesh_dir)/cart_file
    set outputfile $file_name(transfer_dir)/hp

    set domain [domain_select $file_name(domains_dir) "Select an unstructured domain." \
	unstruct 0]
    if {$domain == {}} return

    if {![dialog .hp "HP" \
      "Please edit the following HP options." {
	{cart_file -type path -title "Cartesian File from Global"}
        {outputfile -type path -title "Output HP File"}
    }]} return

    set command "\"$hp_output_path\" -dom \"$domain\" -cart \"$cart_file\" \"$outputfile\""
    runxcom ICEM-CFD/HP-Interface $command "" 1 0
}
