Пример #1
0
int main(int argc, const char * argv[])
{

    // insert code here...
    char *input = "input.txt";
    char *out1 = "outFile1";
    char *out2 = "outFile2";
    
    processTextFile(input, out1); //It takes input.txt as input, and output a file named outFile1.
    
    // The output file of processTextFile() becomes the input of the following function,
    // sortLines() which takes outFile1 as input and outputs outFile2.
    sortLines(out1, out2);
    
    //printf("Done processing!\n");
    return 0;
}
motion_selector::motion_selector(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::motion_selector)
{
    ui->setupUi(this);
    sliderVal = 1.00;
    processTextFile(QString::fromStdString(ros::package::getPath("vigir_ocs_motion_selector") + "/src/tree.txt"));
    setupQuickButtons(QString::fromStdString(ros::package::getPath("vigir_ocs_motion_selector") + "/src/quickButtons.txt"));
    //ros::
    std::cout << "File done processing now populatin the tree." << std::endl;
    populateTree();

    message_pub_ = nh_.advertise<vigir_control_msgs::FlorExecuteMotionRequest>( "/flor/motion_service/motion_command",1,false);

    //key_event_sub_ = nh_.subscribe<vigir_ocs_msgs::OCSKeyEvent>( "/flor/ocs/key_event", 5, &motion_selector::processNewKeyEvent, this );

    timer.start(33, this);
}