Пример #1
0
 private void slider_ValueChanged(object sender, RoutedPropertyChangedEventArgs <double> e)
 {
     try
     {
         skel               = data_skel[(int)slider.Value];
         skel_centered      = TheUKI.UKI_DataRaw_centerize(skel, 3);
         txtCurrent.Content = skel.id;
         update();
     }
     catch { }
 }
Пример #2
0
        private void butBrowse_Click(object sender, RoutedEventArgs e)
        {
            Nullable <bool> openDialog = TheTool.openFileDialog_01(false, ".*", "");

            if (openDialog == true && TheTool.dialog.FileNames.Count() > 0)
            {
                this.fileFullPath = TheTool.dialog.FileNames[0];
                this.fileFolder   = System.IO.Path.GetDirectoryName(fileFullPath);
                this.fileName     = TheTool.getFileName_byPath(fileFullPath);
                Title             = TheTool.getFileName_byPath(fileName);
                List <UKI_DataRaw> data = new List <UKI_DataRaw>();
                if (TheTool.getExtension_byPath(this.fileFullPath) == ".csv")
                {
                    data.AddRange(TheUKI.csv_loadFileTo_DataRaw(fileFullPath, 0));
                    if (checkFPSauto.IsChecked.Value)
                    {
                        txtFPS.Text = "20";
                    }
                }
                else if (TheTool.getExtension_byPath(this.fileFullPath) == ".bvh")
                {
                    data.AddRange(TheConverter.BVH_convert(fileFullPath));
                    TheUKI.saveData_Raw(fileFolder + @"/" + fileName + "(copy).csv", data);
                    if (checkFPSauto.IsChecked.Value)
                    {
                        txtFPS.Text = "120";
                    }
                }
                if (checkCamera.IsChecked.Value)
                {
                    data = TheUKI.UKI_DataRaw_centerize(data, 3);
                }
                loadData(data);
                txtMark.Text = "";
                mark_count   = 0;
            }
        }