Beispiel #1
0
        private async void Open_Button_Click(object sender, RoutedEventArgs e)
        {
            var picker = new Windows.Storage.Pickers.FileOpenPicker();

            picker.ViewMode = Windows.Storage.Pickers.PickerViewMode.Thumbnail;
            picker.SuggestedStartLocation =
                Windows.Storage.Pickers.PickerLocationId.ComputerFolder;
            picker.FileTypeFilter.Add(".obj");
            Windows.Storage.StorageFile file = await picker.PickSingleFileAsync();

            if (file != null)
            {
                // Application now has read/write access to the picked file
                //this.resultBox.Text = "Picked object: " + file.Name+" path: " +file.Path;

                refiner.addInitModel(file.Name);
                var dialog = new MessageDialog("Test, added model");
                resultBox.Text = refiner.getSize().ToString() + " triangles";
            }
            else
            {
                this.resultBox.Text = "Operation cancelled.";
            }
        }
Beispiel #2
0
 public void addInitModel(String path)
 {
     nativeRefiner.addInitModel(path);
 }