diff --git a/Cupola/Cupola.cs b/Cupola/Cupola.cs index 147813a..28d3be7 100644 --- a/Cupola/Cupola.cs +++ b/Cupola/Cupola.cs @@ -2,7 +2,8 @@ namespace Cupola { - internal partial class Program + public partial class Cupola + { public static void RunSingle(string imgDir, string outDir) { diff --git a/Tranquility/MainWindow.xaml.cs b/Tranquility/MainWindow.xaml.cs index 8ee4f34..19ef420 100644 --- a/Tranquility/MainWindow.xaml.cs +++ b/Tranquility/MainWindow.xaml.cs @@ -4,6 +4,7 @@ using WinRT; using Cupola; using System.IO; using System; +using ComputeSharp; namespace Tranquility { @@ -13,7 +14,8 @@ namespace Tranquility public partial class MainWindow : Window { string[]? files; - + ReadWriteTexture2D? finalImage; + public MainWindow() { InitializeComponent(); @@ -50,7 +52,12 @@ namespace Tranquility private void Run(object sender, RoutedEventArgs e) { + if (files == null) + throw new Exception("Please select files before running"); + ReadWriteTexture2D[] images = Cupola.Cupola.Load(files); + + finalImage = Cupola.Cupola.RunSingle(images); } } }