├── Release ├── FlipbookTool.exe └── ImageProcessor.dll ├── FlipbookTool ├── App.config ├── packages.config ├── Properties │ ├── Settings.settings │ ├── Settings.Designer.cs │ ├── AssemblyInfo.cs │ ├── Resources.Designer.cs │ └── Resources.resx ├── Program.cs ├── Form1.cs ├── ResizeForm.cs ├── DissectForm.cs ├── FlipbookTool.csproj ├── PreviewForm.cs ├── Utils.cs ├── Form1.Designer.cs ├── AssembleForm.cs ├── AssembleForm.Designer.cs ├── DissectForm.Designer.cs ├── ResizeForm.Designer.cs └── PreviewForm.Designer.cs ├── README.md ├── FlipbookTool.sln ├── .gitattributes └── .gitignore /Release/FlipbookTool.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Go0gle-Chr0me/FlipbookTool/HEAD/Release/FlipbookTool.exe -------------------------------------------------------------------------------- /Release/ImageProcessor.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Go0gle-Chr0me/FlipbookTool/HEAD/Release/ImageProcessor.dll -------------------------------------------------------------------------------- /FlipbookTool/App.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /FlipbookTool/packages.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /FlipbookTool/Properties/Settings.settings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | # FlipbookTool 4 | 5 | Tool to edit or create fliopbook particle textures 6 | 7 | https://streamable.com/9ssinw 8 | 9 | video example of how to turn this flipbook : 10 | 11 | 12 | 13 | into this one : 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /FlipbookTool/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using System.Windows.Forms; 6 | 7 | namespace FlipbookTool 8 | { 9 | static class Program 10 | { 11 | /// 12 | /// The main entry point for the application. 13 | /// 14 | [STAThread] 15 | static void Main() 16 | { 17 | Application.EnableVisualStyles(); 18 | Application.SetCompatibleTextRenderingDefault(false); 19 | Application.Run(new Menu()); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /FlipbookTool.sln: -------------------------------------------------------------------------------- 1 | 2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio Version 16 4 | VisualStudioVersion = 16.0.33423.256 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FlipbookTool", "FlipbookTool\FlipbookTool.csproj", "{585AA0FB-72A0-4C01-8B01-6702C9A6F066}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Any CPU = Debug|Any CPU 11 | Release|Any CPU = Release|Any CPU 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {585AA0FB-72A0-4C01-8B01-6702C9A6F066}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 15 | {585AA0FB-72A0-4C01-8B01-6702C9A6F066}.Debug|Any CPU.Build.0 = Debug|Any CPU 16 | {585AA0FB-72A0-4C01-8B01-6702C9A6F066}.Release|Any CPU.ActiveCfg = Release|Any CPU 17 | {585AA0FB-72A0-4C01-8B01-6702C9A6F066}.Release|Any CPU.Build.0 = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | GlobalSection(ExtensibilityGlobals) = postSolution 23 | SolutionGuid = {6437EA05-44EF-4182-AE06-01C89395AA0E} 24 | EndGlobalSection 25 | EndGlobal 26 | -------------------------------------------------------------------------------- /FlipbookTool/Properties/Settings.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.42000 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | 12 | namespace FlipbookTool.Properties 13 | { 14 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 15 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")] 16 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase 17 | { 18 | 19 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); 20 | 21 | public static Settings Default 22 | { 23 | get 24 | { 25 | return defaultInstance; 26 | } 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /FlipbookTool/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("FlipbookTool")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("FlipbookTool")] 13 | [assembly: AssemblyCopyright("Copyright © 2023")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("585aa0fb-72a0-4c01-8b01-6702c9a6f066")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /FlipbookTool/Form1.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | 11 | namespace FlipbookTool 12 | { 13 | public partial class Menu : Form 14 | { 15 | 16 | private void SetupPromptFormButton(Button button, Form formObject) 17 | { 18 | 19 | button.MouseClick += (s, e) => 20 | { 21 | 22 | formObject.Show(); 23 | }; 24 | 25 | } 26 | 27 | public Menu() 28 | { 29 | InitializeComponent(); 30 | Utils.RoundCorners(this); 31 | Utils.MakeDraggable(this, Handle); 32 | Utils.MakeDraggable(this.Title, Handle); 33 | Utils.SetupButton(this.ResizeButton); 34 | Utils.SetupButton(this.DissectButton); 35 | Utils.SetupButton(this.AssembleButton); 36 | Utils.SetupButton(this.PreviewButton); 37 | Utils.SetupButton(this.CloseButton); 38 | 39 | CloseButton.MouseClick += (s, e) => 40 | { 41 | Application.Exit(); 42 | }; 43 | 44 | SetupPromptFormButton(ResizeButton, new ResizeForm()); 45 | SetupPromptFormButton(DissectButton, new DissectForm()); 46 | SetupPromptFormButton(AssembleButton, new AssembleForm()); 47 | SetupPromptFormButton(PreviewButton, new PreviewForm()); 48 | } 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | ############################################################################### 2 | # Set default behavior to automatically normalize line endings. 3 | ############################################################################### 4 | * text=auto 5 | 6 | ############################################################################### 7 | # Set default behavior for command prompt diff. 8 | # 9 | # This is need for earlier builds of msysgit that does not have it on by 10 | # default for csharp files. 11 | # Note: This is only used by command line 12 | ############################################################################### 13 | #*.cs diff=csharp 14 | 15 | ############################################################################### 16 | # Set the merge driver for project and solution files 17 | # 18 | # Merging from the command prompt will add diff markers to the files if there 19 | # are conflicts (Merging from VS is not affected by the settings below, in VS 20 | # the diff markers are never inserted). Diff markers may cause the following 21 | # file extensions to fail to load in VS. An alternative would be to treat 22 | # these files as binary and thus will always conflict and require user 23 | # intervention with every merge. To do so, just uncomment the entries below 24 | ############################################################################### 25 | #*.sln merge=binary 26 | #*.csproj merge=binary 27 | #*.vbproj merge=binary 28 | #*.vcxproj merge=binary 29 | #*.vcproj merge=binary 30 | #*.dbproj merge=binary 31 | #*.fsproj merge=binary 32 | #*.lsproj merge=binary 33 | #*.wixproj merge=binary 34 | #*.modelproj merge=binary 35 | #*.sqlproj merge=binary 36 | #*.wwaproj merge=binary 37 | 38 | ############################################################################### 39 | # behavior for image files 40 | # 41 | # image files are treated as binary by default. 42 | ############################################################################### 43 | #*.jpg binary 44 | #*.png binary 45 | #*.gif binary 46 | 47 | ############################################################################### 48 | # diff behavior for common document formats 49 | # 50 | # Convert binary document formats to text before diffing them. This feature 51 | # is only available from the command line. Turn it on by uncommenting the 52 | # entries below. 53 | ############################################################################### 54 | #*.doc diff=astextplain 55 | #*.DOC diff=astextplain 56 | #*.docx diff=astextplain 57 | #*.DOCX diff=astextplain 58 | #*.dot diff=astextplain 59 | #*.DOT diff=astextplain 60 | #*.pdf diff=astextplain 61 | #*.PDF diff=astextplain 62 | #*.rtf diff=astextplain 63 | #*.RTF diff=astextplain 64 | -------------------------------------------------------------------------------- /FlipbookTool/Properties/Resources.Designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // Runtime Version:4.0.30319.42000 5 | // 6 | // Changes to this file may cause incorrect behavior and will be lost if 7 | // the code is regenerated. 8 | // 9 | //------------------------------------------------------------------------------ 10 | 11 | 12 | namespace FlipbookTool.Properties 13 | { 14 | /// 15 | /// A strongly-typed resource class, for looking up localized strings, etc. 16 | /// 17 | // This class was auto-generated by the StronglyTypedResourceBuilder 18 | // class via a tool like ResGen or Visual Studio. 19 | // To add or remove a member, edit your .ResX file then rerun ResGen 20 | // with the /str option, or rebuild your VS project. 21 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] 22 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] 23 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] 24 | internal class Resources 25 | { 26 | 27 | private static global::System.Resources.ResourceManager resourceMan; 28 | 29 | private static global::System.Globalization.CultureInfo resourceCulture; 30 | 31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] 32 | internal Resources() 33 | { 34 | } 35 | 36 | /// 37 | /// Returns the cached ResourceManager instance used by this class. 38 | /// 39 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 40 | internal static global::System.Resources.ResourceManager ResourceManager 41 | { 42 | get 43 | { 44 | if ((resourceMan == null)) 45 | { 46 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("FlipbookTool.Properties.Resources", typeof(Resources).Assembly); 47 | resourceMan = temp; 48 | } 49 | return resourceMan; 50 | } 51 | } 52 | 53 | /// 54 | /// Overrides the current thread's CurrentUICulture property for all 55 | /// resource lookups using this strongly typed resource class. 56 | /// 57 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] 58 | internal static global::System.Globalization.CultureInfo Culture 59 | { 60 | get 61 | { 62 | return resourceCulture; 63 | } 64 | set 65 | { 66 | resourceCulture = value; 67 | } 68 | } 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /FlipbookTool/ResizeForm.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Drawing; 3 | using System.Windows.Forms; 4 | using System.Threading.Tasks; 5 | using ImageProcessor; 6 | 7 | namespace FlipbookTool 8 | { 9 | public partial class ResizeForm : Form 10 | { 11 | public ResizeForm() 12 | { 13 | InitializeComponent(); 14 | 15 | Utils.RoundCorners(this); 16 | Utils.RoundCorners(this.WidthTextbox); 17 | Utils.RoundCorners(this.HeightTextbox); 18 | Utils.MakeDraggable(this, Handle); 19 | Utils.MakeDraggable(this.Title, Handle); 20 | Utils.MakeDraggable(this.Title2, Handle); 21 | Utils.MakeDraggable(this.panel1, Handle); 22 | Utils.MakeDraggable(this.panel2, Handle); 23 | Utils.MakeDraggable(this.panel3, Handle); 24 | Utils.MakeDraggable(this.ImageFrame, Handle); 25 | Utils.SetupButton(this.ImportButton); 26 | Utils.SetupButton(this.ExportButton); 27 | Utils.SetupButton(this.CloseButton); 28 | 29 | Utils.SetupTextBoxPlaceholder(this.WidthTextbox); 30 | Utils.LimitTextboxToNumbers(this.WidthTextbox); 31 | 32 | CloseButton.MouseClick += (s, e) => 33 | { 34 | this.Hide(); 35 | }; 36 | 37 | ImportButton.MouseClick += (s, e) => 38 | { 39 | Image importedImage = Utils.OpenImageDialog(); 40 | if (importedImage != null) 41 | { 42 | ImageFrame.Image = importedImage; 43 | } 44 | }; 45 | 46 | WidthTextbox.TextChanged += (s, e) => 47 | { 48 | if (WidthTextbox.Text == "Width") 49 | { 50 | HeightTextbox.Text = "Height"; 51 | HeightTextbox.ForeColor = Color.FromArgb(178, 178, 178); 52 | } 53 | else 54 | { 55 | HeightTextbox.Text = WidthTextbox.Text; 56 | HeightTextbox.ForeColor = Color.White; 57 | } 58 | }; 59 | 60 | ExportButton.MouseClick += async (s, e) => 61 | { 62 | String Width = WidthTextbox.Text; 63 | Image image = ImageFrame.Image; 64 | 65 | 66 | if (image == null) 67 | { 68 | ImageFrame.BackColor = Color.FromArgb(244, 41, 41); 69 | await Task.Delay(200); 70 | ImageFrame.BackColor = Color.FromArgb(20, 20, 20); 71 | await Task.Delay(200); 72 | ImageFrame.BackColor = Color.FromArgb(244, 41, 41); 73 | await Task.Delay(200); 74 | ImageFrame.BackColor = Color.FromArgb(20, 20, 20); 75 | return; 76 | } 77 | 78 | int dimension; 79 | 80 | if (!int.TryParse(Width, out dimension)) 81 | { 82 | WidthTextbox.BackColor = Color.FromArgb(244, 41, 41); 83 | await Task.Delay(200); 84 | WidthTextbox.BackColor = Color.FromArgb(40, 40, 40); 85 | await Task.Delay(200); 86 | WidthTextbox.BackColor = Color.FromArgb(244, 41, 41); 87 | await Task.Delay(200); 88 | WidthTextbox.BackColor = Color.FromArgb(40, 40, 40); 89 | return; 90 | }; 91 | 92 | dimension = (dimension == 0 ? 1 : dimension); 93 | 94 | Size newImageSize = new Size(); 95 | newImageSize.Width = dimension; 96 | newImageSize.Height = dimension; 97 | 98 | ImageProcessor.Imaging.ResizeLayer resize = new ImageProcessor.Imaging.ResizeLayer(newImageSize, ImageProcessor.Imaging.ResizeMode.Stretch); 99 | 100 | ImageFactory editor = new ImageFactory(); 101 | editor.Load(image).Resize(resize).Format(new ImageProcessor.Imaging.Formats.PngFormat()); 102 | 103 | String fileName = Utils.SaveImageDialog(); 104 | if (fileName != null) 105 | { 106 | editor.Save(fileName); 107 | } 108 | 109 | 110 | }; 111 | 112 | } 113 | 114 | } 115 | } 116 | -------------------------------------------------------------------------------- /FlipbookTool/DissectForm.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | using ImageProcessor; 11 | 12 | namespace FlipbookTool 13 | { 14 | public partial class DissectForm : Form 15 | { 16 | public DissectForm() 17 | { 18 | InitializeComponent(); 19 | 20 | Utils.RoundCorners(this); 21 | Utils.RoundCorners(this.RowsTextbox); 22 | Utils.RoundCorners(this.ColumnsTextbox); 23 | Utils.MakeDraggable(this, Handle); 24 | Utils.MakeDraggable(this.Title, Handle); 25 | Utils.MakeDraggable(this.Title2, Handle); 26 | Utils.MakeDraggable(this.ImageFrame, Handle); 27 | Utils.SetupButton(this.ImportButton); 28 | Utils.SetupButton(this.DissectButton); 29 | Utils.SetupButton(this.CloseButton); 30 | 31 | Utils.SetupTextBoxPlaceholder(this.RowsTextbox); 32 | Utils.LimitTextboxToNumbers(this.RowsTextbox); 33 | 34 | Utils.SetupTextBoxPlaceholder(this.ColumnsTextbox); 35 | Utils.LimitTextboxToNumbers(this.ColumnsTextbox); 36 | 37 | CloseButton.MouseClick += (s, e) => 38 | { 39 | this.Hide(); 40 | }; 41 | 42 | ImportButton.MouseClick += (s, e) => 43 | { 44 | Image importedImage = Utils.OpenImageDialog(); 45 | if (importedImage != null) 46 | { 47 | ImageFrame.Image = importedImage; 48 | } 49 | }; 50 | 51 | DissectButton.MouseClick += async (s, e) => 52 | { 53 | String rowsText = RowsTextbox.Text; 54 | String columnsText = ColumnsTextbox.Text; 55 | Image image = ImageFrame.Image; 56 | 57 | 58 | if (image == null) 59 | { 60 | ImageFrame.BackColor = Color.FromArgb(244, 41, 41); 61 | await Task.Delay(200); 62 | ImageFrame.BackColor = Color.FromArgb(20, 20, 20); 63 | await Task.Delay(200); 64 | ImageFrame.BackColor = Color.FromArgb(244, 41, 41); 65 | await Task.Delay(200); 66 | ImageFrame.BackColor = Color.FromArgb(20, 20, 20); 67 | return; 68 | } 69 | 70 | int rows; 71 | 72 | if (!int.TryParse(rowsText, out rows)) 73 | { 74 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 75 | await Task.Delay(200); 76 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 77 | await Task.Delay(200); 78 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 79 | await Task.Delay(200); 80 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 81 | return; 82 | }; 83 | 84 | int columns; 85 | 86 | if (!int.TryParse(columnsText, out columns)) 87 | { 88 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 89 | await Task.Delay(200); 90 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 91 | await Task.Delay(200); 92 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 93 | await Task.Delay(200); 94 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 95 | return; 96 | }; 97 | 98 | rows = (rows == 0 ? 1 : rows); 99 | columns = (columns == 0 ? 1 : columns); 100 | 101 | String folderName = Utils.SaveFolderDialog(); 102 | if (folderName != null) 103 | { 104 | 105 | int XSize = image.Width / columns; 106 | int YSize = image.Height / rows; 107 | 108 | Size imageSize = new Size(); 109 | imageSize.Width = XSize; 110 | imageSize.Height = YSize; 111 | 112 | for (int row = 1; row <= rows; row++) 113 | { 114 | for (int column = 1; column <= columns; column++) 115 | { 116 | ImageFactory editor = new ImageFactory(); 117 | editor.Load(image); 118 | 119 | Point imagePosition = new Point(); 120 | imagePosition.X = (column - 1) * XSize; 121 | imagePosition.Y = (row - 1) * YSize; 122 | 123 | Rectangle cropRectangle = new Rectangle(imagePosition, imageSize); 124 | 125 | editor.Crop(cropRectangle); 126 | editor.Format(new ImageProcessor.Imaging.Formats.PngFormat()); 127 | 128 | editor.Save(folderName + "\\Dissect_" + row + column + ".png"); 129 | editor.Dispose(); 130 | } 131 | } 132 | } 133 | }; 134 | } 135 | } 136 | } 137 | -------------------------------------------------------------------------------- /FlipbookTool/FlipbookTool.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {585AA0FB-72A0-4C01-8B01-6702C9A6F066} 8 | WinExe 9 | FlipbookTool 10 | FlipbookTool 11 | v4.7.2 12 | 512 13 | true 14 | true 15 | 16 | 17 | AnyCPU 18 | true 19 | full 20 | false 21 | bin\Debug\ 22 | DEBUG;TRACE 23 | prompt 24 | 4 25 | 26 | 27 | AnyCPU 28 | pdbonly 29 | true 30 | bin\Release\ 31 | TRACE 32 | prompt 33 | 4 34 | 35 | 36 | 37 | ..\packages\ImageProcessor.2.9.1\lib\net452\ImageProcessor.dll 38 | 39 | 40 | 41 | 42 | ..\packages\System.ValueTuple.4.5.0\lib\net47\System.ValueTuple.dll 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | Form 57 | 58 | 59 | AssembleForm.cs 60 | 61 | 62 | Form 63 | 64 | 65 | DissectForm.cs 66 | 67 | 68 | Form 69 | 70 | 71 | Form1.cs 72 | 73 | 74 | Form 75 | 76 | 77 | PreviewForm.cs 78 | 79 | 80 | 81 | 82 | Form 83 | 84 | 85 | ResizeForm.cs 86 | 87 | 88 | 89 | AssembleForm.cs 90 | 91 | 92 | DissectForm.cs 93 | 94 | 95 | Form1.cs 96 | 97 | 98 | PreviewForm.cs 99 | 100 | 101 | ResXFileCodeGenerator 102 | Resources.Designer.cs 103 | Designer 104 | 105 | 106 | True 107 | Resources.resx 108 | 109 | 110 | ResizeForm.cs 111 | 112 | 113 | 114 | SettingsSingleFileGenerator 115 | Settings.Designer.cs 116 | 117 | 118 | True 119 | Settings.settings 120 | True 121 | 122 | 123 | 124 | 125 | 126 | 127 | -------------------------------------------------------------------------------- /FlipbookTool/Properties/Resources.resx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | text/microsoft-resx 107 | 108 | 109 | 2.0 110 | 111 | 112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 113 | 114 | 115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 116 | 117 | -------------------------------------------------------------------------------- /FlipbookTool/PreviewForm.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | using ImageProcessor; 11 | 12 | namespace FlipbookTool 13 | { 14 | public partial class PreviewForm : Form 15 | { 16 | public PreviewForm() 17 | { 18 | InitializeComponent(); 19 | 20 | Utils.RoundCorners(this); 21 | Utils.RoundCorners(this.RowsTextbox); 22 | Utils.RoundCorners(this.ColumnsTextbox); 23 | Utils.RoundCorners(this.SecondsTextbox); 24 | Utils.MakeDraggable(this, Handle); 25 | Utils.MakeDraggable(this.Title, Handle); 26 | Utils.MakeDraggable(this.Title2, Handle); 27 | Utils.MakeDraggable(this.ImageFrame, Handle); 28 | Utils.MakeDraggable(this.OutputFrame, Handle); 29 | Utils.SetupButton(this.ImportButton); 30 | Utils.SetupButton(this.PlayButton); 31 | Utils.SetupButton(this.CloseButton); 32 | 33 | Utils.SetupTextBoxPlaceholder(this.RowsTextbox); 34 | Utils.LimitTextboxToNumbers(this.RowsTextbox); 35 | 36 | Utils.SetupTextBoxPlaceholder(this.ColumnsTextbox); 37 | Utils.LimitTextboxToNumbers(this.ColumnsTextbox); 38 | 39 | Utils.SetupTextBoxPlaceholder(this.SecondsTextbox); 40 | Utils.LimitTextboxToNumbers(this.SecondsTextbox); 41 | 42 | CloseButton.MouseClick += (s, e) => 43 | { 44 | this.Hide(); 45 | }; 46 | 47 | long lastTimeImport = 0; 48 | long lastTimePlay = 0; 49 | int lastRows = 0; 50 | int lastColumns = 0; 51 | Image[] lastFrames = new Image[64]; 52 | 53 | ImportButton.MouseClick += (s, e) => 54 | { 55 | Image importedImage = Utils.OpenImageDialog(); 56 | if (importedImage != null) 57 | { 58 | ImageFrame.Image = importedImage; 59 | lastTimeImport = DateTime.Now.Ticks; 60 | } 61 | }; 62 | 63 | PlayButton.MouseClick += async (s, e) => 64 | { 65 | String rowsText = RowsTextbox.Text; 66 | String columnsText = ColumnsTextbox.Text; 67 | String secondsText = SecondsTextbox.Text; 68 | Image image = ImageFrame.Image; 69 | 70 | 71 | if (image == null) 72 | { 73 | ImageFrame.BackColor = Color.FromArgb(244, 41, 41); 74 | await Task.Delay(200); 75 | ImageFrame.BackColor = Color.FromArgb(20, 20, 20); 76 | await Task.Delay(200); 77 | ImageFrame.BackColor = Color.FromArgb(244, 41, 41); 78 | await Task.Delay(200); 79 | ImageFrame.BackColor = Color.FromArgb(20, 20, 20); 80 | return; 81 | } 82 | 83 | int rows; 84 | 85 | if (!int.TryParse(rowsText, out rows)) 86 | { 87 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 88 | await Task.Delay(200); 89 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 90 | await Task.Delay(200); 91 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 92 | await Task.Delay(200); 93 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 94 | return; 95 | }; 96 | 97 | int columns; 98 | 99 | if (!int.TryParse(columnsText, out columns)) 100 | { 101 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 102 | await Task.Delay(200); 103 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 104 | await Task.Delay(200); 105 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 106 | await Task.Delay(200); 107 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 108 | return; 109 | }; 110 | 111 | float seconds; 112 | 113 | if (!float.TryParse(secondsText, out seconds)) 114 | { 115 | SecondsTextbox.BackColor = Color.FromArgb(244, 41, 41); 116 | await Task.Delay(200); 117 | SecondsTextbox.BackColor = Color.FromArgb(40, 40, 40); 118 | await Task.Delay(200); 119 | SecondsTextbox.BackColor = Color.FromArgb(244, 41, 41); 120 | await Task.Delay(200); 121 | SecondsTextbox.BackColor = Color.FromArgb(40, 40, 40); 122 | return; 123 | }; 124 | 125 | rows = (rows == 0 ? 1 : rows); 126 | columns = (columns == 0 ? 1 : columns); 127 | seconds = (seconds == 0 ? 0.1f : seconds); 128 | 129 | Image[] frames = new Image[64]; 130 | 131 | if (lastTimeImport > lastTimePlay || rows != lastRows || columns != lastColumns) 132 | { 133 | int XSize = image.Width / columns; 134 | int YSize = image.Height / rows; 135 | 136 | Size imageSize = new Size(); 137 | imageSize.Width = XSize; 138 | imageSize.Height = YSize; 139 | 140 | int frameCount = rows * columns; 141 | 142 | lastRows = rows; 143 | lastColumns = columns; 144 | 145 | frames = new Image[frameCount]; 146 | 147 | int i = 0; 148 | 149 | for (int row = 1; row <= rows; row++) 150 | { 151 | for (int column = 1; column <= columns; column++) 152 | { 153 | ImageFactory editor = new ImageFactory(); 154 | editor.Load(image); 155 | 156 | Point imagePosition = new Point(); 157 | imagePosition.X = (column - 1) * XSize; 158 | imagePosition.Y = (row - 1) * YSize; 159 | 160 | Rectangle cropRectangle = new Rectangle(imagePosition, imageSize); 161 | 162 | editor.Crop(cropRectangle); 163 | editor.Format(new ImageProcessor.Imaging.Formats.PngFormat()); 164 | 165 | frames[i] = editor.Image; 166 | i++; 167 | 168 | } 169 | } 170 | } 171 | else 172 | { 173 | frames = lastFrames; 174 | } 175 | 176 | lastTimePlay = DateTime.Now.Ticks; 177 | lastFrames = frames; 178 | 179 | int DelayTime = (int)(seconds * 1000) / (lastFrames.Length); 180 | 181 | for (int frame = 0; frame < (lastFrames.Length); frame++) 182 | { 183 | OutputFrame.Image = lastFrames[frame]; 184 | await Task.Delay(DelayTime); 185 | } 186 | 187 | OutputFrame.Image = null; 188 | }; 189 | } 190 | } 191 | } 192 | -------------------------------------------------------------------------------- /FlipbookTool/Utils.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Drawing; 3 | using System.Windows.Forms; 4 | using System.Runtime.InteropServices; 5 | 6 | namespace FlipbookTool 7 | { 8 | public class Utils 9 | { 10 | [DllImport("Gdi32.dll", EntryPoint = "CreateRoundRectRgn")] 11 | public static extern IntPtr CreateRoundRectRgn 12 | ( 13 | int nLeftRect, // x-coordinate of upper-left corner 14 | int nTopRect, // y-coordinate of upper-left corner 15 | int nRightRect, // x-coordinate of lower-right corner 16 | int nBottomRect, // y-coordinate of lower-right corner 17 | int nWidthEllipse, // width of ellipse 18 | int nHeightEllipse // height of ellipse 19 | ); 20 | 21 | public const int WM_NCLBUTTONDOWN = 0xA1; 22 | public const int HT_CAPTION = 0x2; 23 | 24 | [System.Runtime.InteropServices.DllImport("user32.dll")] 25 | public static extern int SendMessage(IntPtr hWnd, int Msg, int wParam, int lParam); 26 | [System.Runtime.InteropServices.DllImport("user32.dll")] 27 | public static extern bool ReleaseCapture(); 28 | 29 | public static void RoundCorners(Form form) 30 | { 31 | form.Region = System.Drawing.Region.FromHrgn(CreateRoundRectRgn(0, 0, form.Width, form.Height, 10, 10)); 32 | } 33 | 34 | public static void RoundCorners(Button form) 35 | { 36 | form.Region = System.Drawing.Region.FromHrgn(CreateRoundRectRgn(0, 0, form.Width, form.Height, 10, 10)); 37 | } 38 | 39 | public static void RoundCorners(TextBox form) 40 | { 41 | form.Region = System.Drawing.Region.FromHrgn(CreateRoundRectRgn(0, 0, form.Width, form.Height, 10, 10)); 42 | } 43 | 44 | public static void MakeDraggable(Form form, IntPtr Handle) 45 | { 46 | form.MouseDown += (s, e) => 47 | { 48 | if (e.Button == MouseButtons.Left) 49 | { 50 | ReleaseCapture(); 51 | SendMessage(Handle, WM_NCLBUTTONDOWN, HT_CAPTION, 0); 52 | } 53 | }; 54 | } 55 | 56 | public static void MakeDraggable(Label form, IntPtr Handle) 57 | { 58 | form.MouseDown += (s, e) => 59 | { 60 | if (e.Button == MouseButtons.Left) 61 | { 62 | ReleaseCapture(); 63 | SendMessage(Handle, WM_NCLBUTTONDOWN, HT_CAPTION, 0); 64 | } 65 | }; 66 | } 67 | 68 | public static void MakeDraggable(Panel form, IntPtr Handle) 69 | { 70 | form.MouseDown += (s, e) => 71 | { 72 | if (e.Button == MouseButtons.Left) 73 | { 74 | ReleaseCapture(); 75 | SendMessage(Handle, WM_NCLBUTTONDOWN, HT_CAPTION, 0); 76 | } 77 | }; 78 | } 79 | 80 | public static void MakeDraggable(PictureBox form, IntPtr Handle) 81 | { 82 | form.MouseDown += (s, e) => 83 | { 84 | if (e.Button == MouseButtons.Left) 85 | { 86 | ReleaseCapture(); 87 | SendMessage(Handle, WM_NCLBUTTONDOWN, HT_CAPTION, 0); 88 | } 89 | }; 90 | } 91 | 92 | public static void SetupButton(Button form) 93 | { 94 | RoundCorners(form); 95 | form.MouseEnter += (s, e) => 96 | { 97 | form.BackColor = Color.FromArgb(244, 41, 41); 98 | }; 99 | 100 | form.MouseLeave += (s, e) => 101 | { 102 | form.BackColor = Color.FromArgb(40, 40, 40); 103 | }; 104 | } 105 | 106 | public static void SetupTextBoxPlaceholder(TextBox textbox) 107 | { 108 | String placeholder = textbox.Text; 109 | Color placeholderColor = textbox.ForeColor; 110 | 111 | textbox.GotFocus += (s, e) => 112 | { 113 | if (textbox.Text == placeholder) 114 | { 115 | textbox.Text = ""; 116 | textbox.ForeColor = Color.White; 117 | }; 118 | }; 119 | 120 | textbox.LostFocus += (s, e) => 121 | { 122 | if (textbox.Text == "") 123 | { 124 | textbox.Text = placeholder; 125 | textbox.ForeColor = placeholderColor; 126 | }; 127 | }; 128 | } 129 | 130 | public static void LimitTextboxToNumbers(TextBox textbox) 131 | { 132 | textbox.KeyPress += (s, e) => 133 | { 134 | if (!char.IsControl(e.KeyChar) && !char.IsDigit(e.KeyChar) && (e.KeyChar != '.')) 135 | { 136 | e.Handled = true; 137 | }; 138 | }; 139 | } 140 | 141 | public static Image OpenImageDialog() 142 | { 143 | OpenFileDialog openFileDialog1 = new OpenFileDialog 144 | { 145 | Title = "Browse Image Files", 146 | 147 | CheckFileExists = true, 148 | CheckPathExists = true, 149 | 150 | DefaultExt = "png", 151 | Filter = "Images (*.BMP;*.JPG;*.GIF,*.PNG,*.TIFF)|*.BMP;*.JPG;*.GIF;*.PNG;*.TIFF", 152 | RestoreDirectory = true, 153 | }; 154 | 155 | if (openFileDialog1.ShowDialog() == DialogResult.OK) 156 | { 157 | return Image.FromFile(openFileDialog1.FileName); 158 | } 159 | 160 | return null; 161 | } 162 | 163 | public static Image[] OpenImagesDialog() 164 | { 165 | OpenFileDialog openFileDialog1 = new OpenFileDialog 166 | { 167 | Title = "Browse Image Files", 168 | 169 | CheckFileExists = true, 170 | CheckPathExists = true, 171 | Multiselect = true, 172 | 173 | DefaultExt = "png", 174 | Filter = "Images (*.BMP;*.JPG;*.GIF,*.PNG,*.TIFF)|*.BMP;*.JPG;*.GIF;*.PNG;*.TIFF", 175 | RestoreDirectory = true, 176 | }; 177 | 178 | if (openFileDialog1.ShowDialog() == DialogResult.OK) 179 | { 180 | Image[] imageList = new Image[openFileDialog1.FileNames.Length]; 181 | 182 | int i = 0; 183 | foreach (string fileName in openFileDialog1.FileNames) 184 | { 185 | imageList[i] = Image.FromFile(fileName); 186 | i++; 187 | } 188 | 189 | return imageList; 190 | }; 191 | 192 | return null; 193 | } 194 | 195 | public static String SaveImageDialog() 196 | { 197 | SaveFileDialog saveFileDialog = new SaveFileDialog 198 | { 199 | Title = "Browse Image Files", 200 | 201 | DefaultExt = "png", 202 | Filter = "Image (*.PNG)|*.PNG;", 203 | RestoreDirectory = true, 204 | }; 205 | 206 | if (saveFileDialog.ShowDialog() == DialogResult.OK) 207 | { 208 | return saveFileDialog.FileName; 209 | } 210 | 211 | return null; 212 | } 213 | 214 | public static String SaveFolderDialog() 215 | { 216 | FolderBrowserDialog folderBrowserDialog = new FolderBrowserDialog(); 217 | 218 | if (folderBrowserDialog.ShowDialog() == DialogResult.OK) 219 | { 220 | return folderBrowserDialog.SelectedPath; 221 | } 222 | 223 | return null; 224 | } 225 | } 226 | } 227 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | ## 4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 5 | 6 | # User-specific files 7 | *.rsuser 8 | *.suo 9 | *.user 10 | *.userosscache 11 | *.sln.docstates 12 | 13 | # User-specific files (MonoDevelop/Xamarin Studio) 14 | *.userprefs 15 | 16 | # Mono auto generated files 17 | mono_crash.* 18 | 19 | # Build results 20 | [Dd]ebug/ 21 | [Dd]ebugPublic/ 22 | [Rr]elease/ 23 | [Rr]eleases/ 24 | x64/ 25 | x86/ 26 | [Ww][Ii][Nn]32/ 27 | [Aa][Rr][Mm]/ 28 | [Aa][Rr][Mm]64/ 29 | bld/ 30 | [Bb]in/ 31 | [Oo]bj/ 32 | [Oo]ut/ 33 | [Ll]og/ 34 | [Ll]ogs/ 35 | 36 | # Visual Studio 2015/2017 cache/options directory 37 | .vs/ 38 | # Uncomment if you have tasks that create the project's static files in wwwroot 39 | #wwwroot/ 40 | 41 | # Visual Studio 2017 auto generated files 42 | Generated\ Files/ 43 | 44 | # MSTest test Results 45 | [Tt]est[Rr]esult*/ 46 | [Bb]uild[Ll]og.* 47 | 48 | # NUnit 49 | *.VisualState.xml 50 | TestResult.xml 51 | nunit-*.xml 52 | 53 | # Build Results of an ATL Project 54 | [Dd]ebugPS/ 55 | [Rr]eleasePS/ 56 | dlldata.c 57 | 58 | # Benchmark Results 59 | BenchmarkDotNet.Artifacts/ 60 | 61 | # .NET Core 62 | project.lock.json 63 | project.fragment.lock.json 64 | artifacts/ 65 | 66 | # ASP.NET Scaffolding 67 | ScaffoldingReadMe.txt 68 | 69 | # StyleCop 70 | StyleCopReport.xml 71 | 72 | # Files built by Visual Studio 73 | *_i.c 74 | *_p.c 75 | *_h.h 76 | *.ilk 77 | *.meta 78 | *.obj 79 | *.iobj 80 | *.pch 81 | *.pdb 82 | *.ipdb 83 | *.pgc 84 | *.pgd 85 | *.rsp 86 | *.sbr 87 | *.tlb 88 | *.tli 89 | *.tlh 90 | *.tmp 91 | *.tmp_proj 92 | *_wpftmp.csproj 93 | *.log 94 | *.vspscc 95 | *.vssscc 96 | .builds 97 | *.pidb 98 | *.svclog 99 | *.scc 100 | 101 | # Chutzpah Test files 102 | _Chutzpah* 103 | 104 | # Visual C++ cache files 105 | ipch/ 106 | *.aps 107 | *.ncb 108 | *.opendb 109 | *.opensdf 110 | *.sdf 111 | *.cachefile 112 | *.VC.db 113 | *.VC.VC.opendb 114 | 115 | # Visual Studio profiler 116 | *.psess 117 | *.vsp 118 | *.vspx 119 | *.sap 120 | 121 | # Visual Studio Trace Files 122 | *.e2e 123 | 124 | # TFS 2012 Local Workspace 125 | $tf/ 126 | 127 | # Guidance Automation Toolkit 128 | *.gpState 129 | 130 | # ReSharper is a .NET coding add-in 131 | _ReSharper*/ 132 | *.[Rr]e[Ss]harper 133 | *.DotSettings.user 134 | 135 | # TeamCity is a build add-in 136 | _TeamCity* 137 | 138 | # DotCover is a Code Coverage Tool 139 | *.dotCover 140 | 141 | # AxoCover is a Code Coverage Tool 142 | .axoCover/* 143 | !.axoCover/settings.json 144 | 145 | # Coverlet is a free, cross platform Code Coverage Tool 146 | coverage*.json 147 | coverage*.xml 148 | coverage*.info 149 | 150 | # Visual Studio code coverage results 151 | *.coverage 152 | *.coveragexml 153 | 154 | # NCrunch 155 | _NCrunch_* 156 | .*crunch*.local.xml 157 | nCrunchTemp_* 158 | 159 | # MightyMoose 160 | *.mm.* 161 | AutoTest.Net/ 162 | 163 | # Web workbench (sass) 164 | .sass-cache/ 165 | 166 | # Installshield output folder 167 | [Ee]xpress/ 168 | 169 | # DocProject is a documentation generator add-in 170 | DocProject/buildhelp/ 171 | DocProject/Help/*.HxT 172 | DocProject/Help/*.HxC 173 | DocProject/Help/*.hhc 174 | DocProject/Help/*.hhk 175 | DocProject/Help/*.hhp 176 | DocProject/Help/Html2 177 | DocProject/Help/html 178 | 179 | # Click-Once directory 180 | publish/ 181 | 182 | # Publish Web Output 183 | *.[Pp]ublish.xml 184 | *.azurePubxml 185 | # Note: Comment the next line if you want to checkin your web deploy settings, 186 | # but database connection strings (with potential passwords) will be unencrypted 187 | *.pubxml 188 | *.publishproj 189 | 190 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 191 | # checkin your Azure Web App publish settings, but sensitive information contained 192 | # in these scripts will be unencrypted 193 | PublishScripts/ 194 | 195 | # NuGet Packages 196 | *.nupkg 197 | # NuGet Symbol Packages 198 | *.snupkg 199 | # The packages folder can be ignored because of Package Restore 200 | **/[Pp]ackages/* 201 | # except build/, which is used as an MSBuild target. 202 | !**/[Pp]ackages/build/ 203 | # Uncomment if necessary however generally it will be regenerated when needed 204 | #!**/[Pp]ackages/repositories.config 205 | # NuGet v3's project.json files produces more ignorable files 206 | *.nuget.props 207 | *.nuget.targets 208 | 209 | # Microsoft Azure Build Output 210 | csx/ 211 | *.build.csdef 212 | 213 | # Microsoft Azure Emulator 214 | ecf/ 215 | rcf/ 216 | 217 | # Windows Store app package directories and files 218 | AppPackages/ 219 | BundleArtifacts/ 220 | Package.StoreAssociation.xml 221 | _pkginfo.txt 222 | *.appx 223 | *.appxbundle 224 | *.appxupload 225 | 226 | # Visual Studio cache files 227 | # files ending in .cache can be ignored 228 | *.[Cc]ache 229 | # but keep track of directories ending in .cache 230 | !?*.[Cc]ache/ 231 | 232 | # Others 233 | ClientBin/ 234 | ~$* 235 | *~ 236 | *.dbmdl 237 | *.dbproj.schemaview 238 | *.jfm 239 | *.pfx 240 | *.publishsettings 241 | orleans.codegen.cs 242 | 243 | # Including strong name files can present a security risk 244 | # (https://github.com/github/gitignore/pull/2483#issue-259490424) 245 | #*.snk 246 | 247 | # Since there are multiple workflows, uncomment next line to ignore bower_components 248 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 249 | #bower_components/ 250 | 251 | # RIA/Silverlight projects 252 | Generated_Code/ 253 | 254 | # Backup & report files from converting an old project file 255 | # to a newer Visual Studio version. Backup files are not needed, 256 | # because we have git ;-) 257 | _UpgradeReport_Files/ 258 | Backup*/ 259 | UpgradeLog*.XML 260 | UpgradeLog*.htm 261 | ServiceFabricBackup/ 262 | *.rptproj.bak 263 | 264 | # SQL Server files 265 | *.mdf 266 | *.ldf 267 | *.ndf 268 | 269 | # Business Intelligence projects 270 | *.rdl.data 271 | *.bim.layout 272 | *.bim_*.settings 273 | *.rptproj.rsuser 274 | *- [Bb]ackup.rdl 275 | *- [Bb]ackup ([0-9]).rdl 276 | *- [Bb]ackup ([0-9][0-9]).rdl 277 | 278 | # Microsoft Fakes 279 | FakesAssemblies/ 280 | 281 | # GhostDoc plugin setting file 282 | *.GhostDoc.xml 283 | 284 | # Node.js Tools for Visual Studio 285 | .ntvs_analysis.dat 286 | node_modules/ 287 | 288 | # Visual Studio 6 build log 289 | *.plg 290 | 291 | # Visual Studio 6 workspace options file 292 | *.opt 293 | 294 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 295 | *.vbw 296 | 297 | # Visual Studio LightSwitch build output 298 | **/*.HTMLClient/GeneratedArtifacts 299 | **/*.DesktopClient/GeneratedArtifacts 300 | **/*.DesktopClient/ModelManifest.xml 301 | **/*.Server/GeneratedArtifacts 302 | **/*.Server/ModelManifest.xml 303 | _Pvt_Extensions 304 | 305 | # Paket dependency manager 306 | .paket/paket.exe 307 | paket-files/ 308 | 309 | # FAKE - F# Make 310 | .fake/ 311 | 312 | # CodeRush personal settings 313 | .cr/personal 314 | 315 | # Python Tools for Visual Studio (PTVS) 316 | __pycache__/ 317 | *.pyc 318 | 319 | # Cake - Uncomment if you are using it 320 | # tools/** 321 | # !tools/packages.config 322 | 323 | # Tabs Studio 324 | *.tss 325 | 326 | # Telerik's JustMock configuration file 327 | *.jmconfig 328 | 329 | # BizTalk build output 330 | *.btp.cs 331 | *.btm.cs 332 | *.odx.cs 333 | *.xsd.cs 334 | 335 | # OpenCover UI analysis results 336 | OpenCover/ 337 | 338 | # Azure Stream Analytics local run output 339 | ASALocalRun/ 340 | 341 | # MSBuild Binary and Structured Log 342 | *.binlog 343 | 344 | # NVidia Nsight GPU debugger configuration file 345 | *.nvuser 346 | 347 | # MFractors (Xamarin productivity tool) working folder 348 | .mfractor/ 349 | 350 | # Local History for Visual Studio 351 | .localhistory/ 352 | 353 | # BeatPulse healthcheck temp database 354 | healthchecksdb 355 | 356 | # Backup folder for Package Reference Convert tool in Visual Studio 2017 357 | MigrationBackup/ 358 | 359 | # Ionide (cross platform F# VS Code tools) working folder 360 | .ionide/ 361 | 362 | # Fody - auto-generated XML schema 363 | FodyWeavers.xsd -------------------------------------------------------------------------------- /FlipbookTool/Form1.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace FlipbookTool 3 | { 4 | partial class Menu 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Menu)); 33 | this.Title = new System.Windows.Forms.Label(); 34 | this.ResizeButton = new System.Windows.Forms.Button(); 35 | this.DissectButton = new System.Windows.Forms.Button(); 36 | this.AssembleButton = new System.Windows.Forms.Button(); 37 | this.CloseButton = new System.Windows.Forms.Button(); 38 | this.PreviewButton = new System.Windows.Forms.Button(); 39 | this.SuspendLayout(); 40 | // 41 | // Title 42 | // 43 | this.Title.Anchor = System.Windows.Forms.AnchorStyles.Top; 44 | this.Title.AutoSize = true; 45 | this.Title.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 46 | this.Title.Cursor = System.Windows.Forms.Cursors.Default; 47 | this.Title.Font = new System.Drawing.Font("Gadugi", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 48 | this.Title.ForeColor = System.Drawing.Color.White; 49 | this.Title.Location = new System.Drawing.Point(8, 12); 50 | this.Title.Name = "Title"; 51 | this.Title.Size = new System.Drawing.Size(178, 31); 52 | this.Title.TabIndex = 0; 53 | this.Title.Text = "Flipbook Tool"; 54 | this.Title.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 55 | // 56 | // ResizeButton 57 | // 58 | this.ResizeButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 59 | this.ResizeButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 60 | this.ResizeButton.Cursor = System.Windows.Forms.Cursors.Hand; 61 | this.ResizeButton.FlatAppearance.BorderSize = 0; 62 | this.ResizeButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 63 | this.ResizeButton.Font = new System.Drawing.Font("Gadugi", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 64 | this.ResizeButton.ForeColor = System.Drawing.Color.White; 65 | this.ResizeButton.Location = new System.Drawing.Point(6, 53); 66 | this.ResizeButton.Name = "ResizeButton"; 67 | this.ResizeButton.Size = new System.Drawing.Size(227, 42); 68 | this.ResizeButton.TabIndex = 1; 69 | this.ResizeButton.Text = "Resize Image Tool"; 70 | this.ResizeButton.UseVisualStyleBackColor = false; 71 | // 72 | // DissectButton 73 | // 74 | this.DissectButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 75 | this.DissectButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 76 | this.DissectButton.Cursor = System.Windows.Forms.Cursors.Hand; 77 | this.DissectButton.FlatAppearance.BorderSize = 0; 78 | this.DissectButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 79 | this.DissectButton.Font = new System.Drawing.Font("Gadugi", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 80 | this.DissectButton.ForeColor = System.Drawing.Color.White; 81 | this.DissectButton.Location = new System.Drawing.Point(6, 101); 82 | this.DissectButton.Name = "DissectButton"; 83 | this.DissectButton.Size = new System.Drawing.Size(227, 42); 84 | this.DissectButton.TabIndex = 2; 85 | this.DissectButton.Text = "Dissect Tool"; 86 | this.DissectButton.UseVisualStyleBackColor = false; 87 | // 88 | // AssembleButton 89 | // 90 | this.AssembleButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 91 | this.AssembleButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 92 | this.AssembleButton.Cursor = System.Windows.Forms.Cursors.Hand; 93 | this.AssembleButton.FlatAppearance.BorderSize = 0; 94 | this.AssembleButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 95 | this.AssembleButton.Font = new System.Drawing.Font("Gadugi", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 96 | this.AssembleButton.ForeColor = System.Drawing.Color.White; 97 | this.AssembleButton.Location = new System.Drawing.Point(6, 149); 98 | this.AssembleButton.Name = "AssembleButton"; 99 | this.AssembleButton.Size = new System.Drawing.Size(227, 42); 100 | this.AssembleButton.TabIndex = 3; 101 | this.AssembleButton.Text = "Assemble Tool"; 102 | this.AssembleButton.UseVisualStyleBackColor = false; 103 | // 104 | // CloseButton 105 | // 106 | this.CloseButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 107 | this.CloseButton.Cursor = System.Windows.Forms.Cursors.Hand; 108 | this.CloseButton.FlatAppearance.BorderSize = 0; 109 | this.CloseButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 110 | this.CloseButton.Font = new System.Drawing.Font("Comic Sans MS", 14F); 111 | this.CloseButton.ForeColor = System.Drawing.Color.White; 112 | this.CloseButton.ImageAlign = System.Drawing.ContentAlignment.TopCenter; 113 | this.CloseButton.Location = new System.Drawing.Point(192, 7); 114 | this.CloseButton.Name = "CloseButton"; 115 | this.CloseButton.Size = new System.Drawing.Size(40, 40); 116 | this.CloseButton.TabIndex = 4; 117 | this.CloseButton.Text = "X"; 118 | this.CloseButton.UseVisualStyleBackColor = false; 119 | // 120 | // PreviewButton 121 | // 122 | this.PreviewButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 123 | this.PreviewButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 124 | this.PreviewButton.Cursor = System.Windows.Forms.Cursors.Hand; 125 | this.PreviewButton.FlatAppearance.BorderSize = 0; 126 | this.PreviewButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 127 | this.PreviewButton.Font = new System.Drawing.Font("Gadugi", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 128 | this.PreviewButton.ForeColor = System.Drawing.Color.White; 129 | this.PreviewButton.Location = new System.Drawing.Point(5, 197); 130 | this.PreviewButton.Name = "PreviewButton"; 131 | this.PreviewButton.Size = new System.Drawing.Size(227, 42); 132 | this.PreviewButton.TabIndex = 5; 133 | this.PreviewButton.Text = "Preview Tool"; 134 | this.PreviewButton.UseVisualStyleBackColor = false; 135 | // 136 | // Menu 137 | // 138 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 139 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 140 | this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 141 | this.ClientSize = new System.Drawing.Size(240, 247); 142 | this.Controls.Add(this.PreviewButton); 143 | this.Controls.Add(this.CloseButton); 144 | this.Controls.Add(this.AssembleButton); 145 | this.Controls.Add(this.DissectButton); 146 | this.Controls.Add(this.ResizeButton); 147 | this.Controls.Add(this.Title); 148 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; 149 | this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); 150 | this.MaximizeBox = false; 151 | this.MinimizeBox = false; 152 | this.Name = "Menu"; 153 | this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; 154 | this.Text = "Flipbook Tool"; 155 | this.ResumeLayout(false); 156 | this.PerformLayout(); 157 | 158 | } 159 | 160 | #endregion 161 | 162 | private System.Windows.Forms.Label Title; 163 | private System.Windows.Forms.Button ResizeButton; 164 | private System.Windows.Forms.Button DissectButton; 165 | private System.Windows.Forms.Button AssembleButton; 166 | private System.Windows.Forms.Button CloseButton; 167 | private System.Windows.Forms.Button PreviewButton; 168 | } 169 | } 170 | 171 | -------------------------------------------------------------------------------- /FlipbookTool/AssembleForm.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.ComponentModel; 4 | using System.Data; 5 | using System.Drawing; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using System.Windows.Forms; 10 | using ImageProcessor; 11 | 12 | namespace FlipbookTool 13 | { 14 | public partial class AssembleForm : Form 15 | { 16 | public AssembleForm() 17 | { 18 | InitializeComponent(); 19 | 20 | 21 | Utils.RoundCorners(this); 22 | Utils.RoundCorners(this.RowsTextbox); 23 | Utils.RoundCorners(this.ColumnsTextbox); 24 | Utils.MakeDraggable(this, Handle); 25 | Utils.MakeDraggable(this.Title, Handle); 26 | Utils.MakeDraggable(this.Title2, Handle); 27 | Utils.MakeDraggable(this.pictureBackground, Handle); 28 | Utils.SetupButton(this.ImportButton); 29 | Utils.SetupButton(this.CloseButton); 30 | Utils.SetupButton(this.ExportButton); 31 | 32 | Utils.SetupTextBoxPlaceholder(this.RowsTextbox); 33 | Utils.LimitTextboxToNumbers(this.RowsTextbox); 34 | 35 | Utils.SetupTextBoxPlaceholder(this.ColumnsTextbox); 36 | Utils.LimitTextboxToNumbers(this.ColumnsTextbox); 37 | 38 | CloseButton.MouseClick += (s, e) => 39 | { 40 | this.Hide(); 41 | }; 42 | 43 | PictureBox[] imageList = new PictureBox[64]; 44 | 45 | async void formatChanged(object s, EventArgs e) 46 | { 47 | String rowsText = RowsTextbox.Text; 48 | String columnsText = ColumnsTextbox.Text; 49 | 50 | int rows, columns; 51 | 52 | if (!int.TryParse(columnsText, out columns)) 53 | { 54 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 55 | await Task.Delay(200); 56 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 57 | await Task.Delay(200); 58 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 59 | await Task.Delay(200); 60 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 61 | return; 62 | }; 63 | 64 | if (!int.TryParse(rowsText, out rows)) 65 | { 66 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 67 | await Task.Delay(200); 68 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 69 | await Task.Delay(200); 70 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 71 | await Task.Delay(200); 72 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 73 | return; 74 | }; 75 | 76 | if (rows > 8) { rows = 8; RowsTextbox.Text = "8"; }; 77 | if (columns > 8) { columns = 8; ColumnsTextbox.Text = "8"; }; 78 | 79 | if (rows < 1) { rows = 1; RowsTextbox.Text = "1"; }; 80 | if (columns < 1) { columns = 1; ColumnsTextbox.Text = "1"; }; 81 | 82 | for (int i = 0; i<64; i++) 83 | { 84 | PictureBox box = imageList[i]; 85 | if (box != null) 86 | { 87 | box.Dispose(); 88 | } 89 | }; 90 | 91 | 92 | //pictureBackground.Visible = false; 93 | 94 | int counter = 0; 95 | int YSize = pictureBackground.Height / rows; 96 | int XSize = pictureBackground.Width / columns; 97 | 98 | Point boxLocation = pictureBackground.Location; 99 | 100 | for (int row = 1; row <= rows; row++) 101 | { 102 | for (int column = 1; column <= columns; column++) 103 | { 104 | 105 | Point imagePosition = new Point(); 106 | imagePosition.X = ((column - 1) * XSize); 107 | imagePosition.Y = ((row - 1) * YSize); 108 | 109 | PictureBox box = new PictureBox(); 110 | 111 | box.Location = imagePosition; 112 | box.Size = new Size(XSize, YSize); 113 | box.BackColor = Color.FromArgb(20, 20, 20); 114 | box.BorderStyle = BorderStyle.FixedSingle; 115 | box.TabIndex = 36; 116 | box.SizeMode = PictureBoxSizeMode.StretchImage; 117 | box.TabStop = false; 118 | box.Name = "Frame" + counter; 119 | box.Parent = pictureBackground; 120 | 121 | box.Show(); 122 | 123 | imageList[counter] = box; 124 | 125 | counter++; 126 | 127 | } 128 | } 129 | 130 | }; 131 | 132 | RowsTextbox.TextChanged += formatChanged; 133 | ColumnsTextbox.TextChanged += formatChanged; 134 | 135 | ImportButton.MouseClick += async (s, e) => 136 | { 137 | int rows; 138 | 139 | if (!int.TryParse(RowsTextbox.Text, out rows)) 140 | { 141 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 142 | await Task.Delay(200); 143 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 144 | await Task.Delay(200); 145 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 146 | await Task.Delay(200); 147 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 148 | return; 149 | }; 150 | 151 | int columns; 152 | 153 | if (!int.TryParse(ColumnsTextbox.Text, out columns)) 154 | { 155 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 156 | await Task.Delay(200); 157 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 158 | await Task.Delay(200); 159 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 160 | await Task.Delay(200); 161 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 162 | return; 163 | }; 164 | 165 | Image[] importedImages = Utils.OpenImagesDialog(); 166 | 167 | if(importedImages != null) 168 | { 169 | for(int i = 0; i 182 | { 183 | int rows; 184 | 185 | if (!int.TryParse(RowsTextbox.Text, out rows)) 186 | { 187 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 188 | await Task.Delay(200); 189 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 190 | await Task.Delay(200); 191 | RowsTextbox.BackColor = Color.FromArgb(244, 41, 41); 192 | await Task.Delay(200); 193 | RowsTextbox.BackColor = Color.FromArgb(40, 40, 40); 194 | return; 195 | }; 196 | 197 | int columns; 198 | 199 | if (!int.TryParse(ColumnsTextbox.Text, out columns)) 200 | { 201 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 202 | await Task.Delay(200); 203 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 204 | await Task.Delay(200); 205 | ColumnsTextbox.BackColor = Color.FromArgb(244, 41, 41); 206 | await Task.Delay(200); 207 | ColumnsTextbox.BackColor = Color.FromArgb(40, 40, 40); 208 | return; 209 | }; 210 | 211 | Image firstImage = imageList[0].Image; 212 | 213 | if (firstImage != null) 214 | { 215 | int XSize = firstImage.Width; 216 | int YSize = firstImage.Height; 217 | 218 | Bitmap finalImage = new Bitmap(XSize * columns, YSize * rows); 219 | 220 | Graphics g = Graphics.FromImage(finalImage); 221 | 222 | int counter = 0; 223 | 224 | for (int row = 1; row <= rows; row++) 225 | { 226 | for (int column = 1; column <= columns; column++) 227 | { 228 | Image frame = imageList[counter].Image; 229 | if (frame != null) 230 | { 231 | Point imagePosition = new Point(); 232 | imagePosition.X = ((column - 1) * XSize); 233 | imagePosition.Y = ((row - 1) * YSize); 234 | 235 | ImageFactory factory = new ImageFactory(); 236 | factory.Load(frame); 237 | 238 | Size newImageSize = new Size(); 239 | newImageSize.Width = XSize; 240 | newImageSize.Height = YSize; 241 | 242 | ImageProcessor.Imaging.ResizeLayer resize = new ImageProcessor.Imaging.ResizeLayer(newImageSize, ImageProcessor.Imaging.ResizeMode.Stretch); 243 | 244 | factory.Resize(resize); 245 | 246 | g.DrawImage(factory.Image, imagePosition); 247 | 248 | } else 249 | { 250 | break; 251 | } 252 | 253 | counter++; 254 | } 255 | } 256 | 257 | String fileName = Utils.SaveImageDialog(); 258 | if (fileName != null) 259 | { 260 | ImageFactory factory = new ImageFactory(); 261 | factory.Load(finalImage); 262 | factory.Format(new ImageProcessor.Imaging.Formats.PngFormat()); 263 | factory.Save(fileName); 264 | } 265 | } 266 | }; 267 | 268 | } 269 | 270 | } 271 | } 272 | -------------------------------------------------------------------------------- /FlipbookTool/AssembleForm.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace FlipbookTool 3 | { 4 | partial class AssembleForm 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(AssembleForm)); 33 | this.ExportButton = new System.Windows.Forms.Button(); 34 | this.Title2 = new System.Windows.Forms.Label(); 35 | this.ColumnsTextbox = new System.Windows.Forms.TextBox(); 36 | this.RowsTextbox = new System.Windows.Forms.TextBox(); 37 | this.ImportButton = new System.Windows.Forms.Button(); 38 | this.CloseButton = new System.Windows.Forms.Button(); 39 | this.Title = new System.Windows.Forms.Label(); 40 | this.pictureBackground = new System.Windows.Forms.Panel(); 41 | this.SuspendLayout(); 42 | // 43 | // ExportButton 44 | // 45 | this.ExportButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 46 | this.ExportButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 47 | this.ExportButton.Cursor = System.Windows.Forms.Cursors.Hand; 48 | this.ExportButton.FlatAppearance.BorderSize = 0; 49 | this.ExportButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 50 | this.ExportButton.Font = new System.Drawing.Font("Gadugi", 18F); 51 | this.ExportButton.ForeColor = System.Drawing.Color.White; 52 | this.ExportButton.Location = new System.Drawing.Point(202, 253); 53 | this.ExportButton.Name = "ExportButton"; 54 | this.ExportButton.Size = new System.Drawing.Size(186, 42); 55 | this.ExportButton.TabIndex = 34; 56 | this.ExportButton.Text = "Export"; 57 | this.ExportButton.UseVisualStyleBackColor = false; 58 | // 59 | // Title2 60 | // 61 | this.Title2.Anchor = System.Windows.Forms.AnchorStyles.Top; 62 | this.Title2.AutoSize = true; 63 | this.Title2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 64 | this.Title2.Cursor = System.Windows.Forms.Cursors.Default; 65 | this.Title2.Font = new System.Drawing.Font("Gadugi", 18F); 66 | this.Title2.ForeColor = System.Drawing.Color.White; 67 | this.Title2.Location = new System.Drawing.Point(202, 61); 68 | this.Title2.Name = "Title2"; 69 | this.Title2.Size = new System.Drawing.Size(186, 28); 70 | this.Title2.TabIndex = 31; 71 | this.Title2.Text = "Flipbook Format"; 72 | this.Title2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 73 | // 74 | // ColumnsTextbox 75 | // 76 | this.ColumnsTextbox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 77 | this.ColumnsTextbox.BorderStyle = System.Windows.Forms.BorderStyle.None; 78 | this.ColumnsTextbox.Cursor = System.Windows.Forms.Cursors.Default; 79 | this.ColumnsTextbox.Font = new System.Drawing.Font("Gadugi", 20F); 80 | this.ColumnsTextbox.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(178)))), ((int)(((byte)(178)))), ((int)(((byte)(178))))); 81 | this.ColumnsTextbox.Location = new System.Drawing.Point(222, 166); 82 | this.ColumnsTextbox.Name = "ColumnsTextbox"; 83 | this.ColumnsTextbox.Size = new System.Drawing.Size(136, 36); 84 | this.ColumnsTextbox.TabIndex = 30; 85 | this.ColumnsTextbox.Text = "Columns"; 86 | this.ColumnsTextbox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; 87 | // 88 | // RowsTextbox 89 | // 90 | this.RowsTextbox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 91 | this.RowsTextbox.BorderStyle = System.Windows.Forms.BorderStyle.None; 92 | this.RowsTextbox.Cursor = System.Windows.Forms.Cursors.IBeam; 93 | this.RowsTextbox.Font = new System.Drawing.Font("Gadugi", 20F); 94 | this.RowsTextbox.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(178)))), ((int)(((byte)(178)))), ((int)(((byte)(178))))); 95 | this.RowsTextbox.Location = new System.Drawing.Point(222, 113); 96 | this.RowsTextbox.Name = "RowsTextbox"; 97 | this.RowsTextbox.Size = new System.Drawing.Size(136, 36); 98 | this.RowsTextbox.TabIndex = 29; 99 | this.RowsTextbox.Text = "Rows"; 100 | this.RowsTextbox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; 101 | // 102 | // ImportButton 103 | // 104 | this.ImportButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 105 | this.ImportButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 106 | this.ImportButton.Cursor = System.Windows.Forms.Cursors.Hand; 107 | this.ImportButton.FlatAppearance.BorderSize = 0; 108 | this.ImportButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 109 | this.ImportButton.Font = new System.Drawing.Font("Gadugi", 18F); 110 | this.ImportButton.ForeColor = System.Drawing.Color.White; 111 | this.ImportButton.Location = new System.Drawing.Point(10, 253); 112 | this.ImportButton.Name = "ImportButton"; 113 | this.ImportButton.Size = new System.Drawing.Size(186, 42); 114 | this.ImportButton.TabIndex = 28; 115 | this.ImportButton.Text = "Import"; 116 | this.ImportButton.UseVisualStyleBackColor = false; 117 | // 118 | // CloseButton 119 | // 120 | this.CloseButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 121 | this.CloseButton.Cursor = System.Windows.Forms.Cursors.Hand; 122 | this.CloseButton.FlatAppearance.BorderSize = 0; 123 | this.CloseButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 124 | this.CloseButton.Font = new System.Drawing.Font("Comic Sans MS", 14F); 125 | this.CloseButton.ForeColor = System.Drawing.Color.White; 126 | this.CloseButton.ImageAlign = System.Drawing.ContentAlignment.TopCenter; 127 | this.CloseButton.Location = new System.Drawing.Point(348, 12); 128 | this.CloseButton.Name = "CloseButton"; 129 | this.CloseButton.Size = new System.Drawing.Size(40, 40); 130 | this.CloseButton.TabIndex = 26; 131 | this.CloseButton.Text = "X"; 132 | this.CloseButton.UseVisualStyleBackColor = false; 133 | // 134 | // Title 135 | // 136 | this.Title.Anchor = System.Windows.Forms.AnchorStyles.Top; 137 | this.Title.AutoSize = true; 138 | this.Title.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 139 | this.Title.Cursor = System.Windows.Forms.Cursors.Default; 140 | this.Title.Font = new System.Drawing.Font("Gadugi", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 141 | this.Title.ForeColor = System.Drawing.Color.White; 142 | this.Title.Location = new System.Drawing.Point(12, 14); 143 | this.Title.Name = "Title"; 144 | this.Title.Size = new System.Drawing.Size(187, 31); 145 | this.Title.TabIndex = 25; 146 | this.Title.Text = "Assemble Tool"; 147 | this.Title.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 148 | // 149 | // pictureBackground 150 | // 151 | this.pictureBackground.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 152 | this.pictureBackground.Location = new System.Drawing.Point(10, 61); 153 | this.pictureBackground.Name = "pictureBackground"; 154 | this.pictureBackground.Size = new System.Drawing.Size(186, 186); 155 | this.pictureBackground.TabIndex = 35; 156 | // 157 | // AssembleForm 158 | // 159 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 160 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 161 | this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 162 | this.ClientSize = new System.Drawing.Size(399, 304); 163 | this.Controls.Add(this.pictureBackground); 164 | this.Controls.Add(this.ExportButton); 165 | this.Controls.Add(this.Title2); 166 | this.Controls.Add(this.ColumnsTextbox); 167 | this.Controls.Add(this.RowsTextbox); 168 | this.Controls.Add(this.ImportButton); 169 | this.Controls.Add(this.CloseButton); 170 | this.Controls.Add(this.Title); 171 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; 172 | this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); 173 | this.Name = "AssembleForm"; 174 | this.Text = "AssembleForm"; 175 | this.ResumeLayout(false); 176 | this.PerformLayout(); 177 | 178 | } 179 | 180 | #endregion 181 | 182 | private System.Windows.Forms.Button ExportButton; 183 | private System.Windows.Forms.Label Title2; 184 | private System.Windows.Forms.TextBox ColumnsTextbox; 185 | private System.Windows.Forms.TextBox RowsTextbox; 186 | private System.Windows.Forms.Button ImportButton; 187 | private System.Windows.Forms.Button CloseButton; 188 | private System.Windows.Forms.Label Title; 189 | private System.Windows.Forms.Panel pictureBackground; 190 | } 191 | } -------------------------------------------------------------------------------- /FlipbookTool/DissectForm.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace FlipbookTool 3 | { 4 | partial class DissectForm 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DissectForm)); 33 | this.ImageFrame = new System.Windows.Forms.PictureBox(); 34 | this.ImportButton = new System.Windows.Forms.Button(); 35 | this.DissectButton = new System.Windows.Forms.Button(); 36 | this.Title = new System.Windows.Forms.Label(); 37 | this.CloseButton = new System.Windows.Forms.Button(); 38 | this.ColumnsTextbox = new System.Windows.Forms.TextBox(); 39 | this.RowsTextbox = new System.Windows.Forms.TextBox(); 40 | this.Title2 = new System.Windows.Forms.Label(); 41 | ((System.ComponentModel.ISupportInitialize)(this.ImageFrame)).BeginInit(); 42 | this.SuspendLayout(); 43 | // 44 | // ImageFrame 45 | // 46 | this.ImageFrame.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 47 | this.ImageFrame.Location = new System.Drawing.Point(12, 52); 48 | this.ImageFrame.Name = "ImageFrame"; 49 | this.ImageFrame.Size = new System.Drawing.Size(186, 186); 50 | this.ImageFrame.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; 51 | this.ImageFrame.TabIndex = 9; 52 | this.ImageFrame.TabStop = false; 53 | // 54 | // ImportButton 55 | // 56 | this.ImportButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 57 | this.ImportButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 58 | this.ImportButton.Cursor = System.Windows.Forms.Cursors.Hand; 59 | this.ImportButton.FlatAppearance.BorderSize = 0; 60 | this.ImportButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 61 | this.ImportButton.Font = new System.Drawing.Font("Gadugi", 18F); 62 | this.ImportButton.ForeColor = System.Drawing.Color.White; 63 | this.ImportButton.Location = new System.Drawing.Point(12, 244); 64 | this.ImportButton.Name = "ImportButton"; 65 | this.ImportButton.Size = new System.Drawing.Size(186, 42); 66 | this.ImportButton.TabIndex = 10; 67 | this.ImportButton.Text = "Import"; 68 | this.ImportButton.UseVisualStyleBackColor = false; 69 | // 70 | // DissectButton 71 | // 72 | this.DissectButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 73 | this.DissectButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 74 | this.DissectButton.Cursor = System.Windows.Forms.Cursors.Hand; 75 | this.DissectButton.FlatAppearance.BorderSize = 0; 76 | this.DissectButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 77 | this.DissectButton.Font = new System.Drawing.Font("Gadugi", 18F); 78 | this.DissectButton.ForeColor = System.Drawing.Color.White; 79 | this.DissectButton.Location = new System.Drawing.Point(204, 244); 80 | this.DissectButton.Name = "DissectButton"; 81 | this.DissectButton.Size = new System.Drawing.Size(186, 42); 82 | this.DissectButton.TabIndex = 13; 83 | this.DissectButton.Text = "Dissect"; 84 | this.DissectButton.UseVisualStyleBackColor = false; 85 | // 86 | // Title 87 | // 88 | this.Title.Anchor = System.Windows.Forms.AnchorStyles.Top; 89 | this.Title.AutoSize = true; 90 | this.Title.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 91 | this.Title.Cursor = System.Windows.Forms.Cursors.Default; 92 | this.Title.Font = new System.Drawing.Font("Gadugi", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 93 | this.Title.ForeColor = System.Drawing.Color.White; 94 | this.Title.Location = new System.Drawing.Point(7, 9); 95 | this.Title.Name = "Title"; 96 | this.Title.Size = new System.Drawing.Size(157, 31); 97 | this.Title.TabIndex = 14; 98 | this.Title.Text = "Dissect Tool"; 99 | this.Title.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 100 | // 101 | // CloseButton 102 | // 103 | this.CloseButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 104 | this.CloseButton.Cursor = System.Windows.Forms.Cursors.Hand; 105 | this.CloseButton.FlatAppearance.BorderSize = 0; 106 | this.CloseButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 107 | this.CloseButton.Font = new System.Drawing.Font("Comic Sans MS", 14F); 108 | this.CloseButton.ForeColor = System.Drawing.Color.White; 109 | this.CloseButton.ImageAlign = System.Drawing.ContentAlignment.TopCenter; 110 | this.CloseButton.Location = new System.Drawing.Point(355, 8); 111 | this.CloseButton.Name = "CloseButton"; 112 | this.CloseButton.Size = new System.Drawing.Size(40, 40); 113 | this.CloseButton.TabIndex = 15; 114 | this.CloseButton.Text = "X"; 115 | this.CloseButton.UseVisualStyleBackColor = false; 116 | // 117 | // ColumnsTextbox 118 | // 119 | this.ColumnsTextbox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 120 | this.ColumnsTextbox.BorderStyle = System.Windows.Forms.BorderStyle.None; 121 | this.ColumnsTextbox.Cursor = System.Windows.Forms.Cursors.Default; 122 | this.ColumnsTextbox.Font = new System.Drawing.Font("Gadugi", 20F); 123 | this.ColumnsTextbox.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(178)))), ((int)(((byte)(178)))), ((int)(((byte)(178))))); 124 | this.ColumnsTextbox.Location = new System.Drawing.Point(225, 179); 125 | this.ColumnsTextbox.Name = "ColumnsTextbox"; 126 | this.ColumnsTextbox.Size = new System.Drawing.Size(136, 36); 127 | this.ColumnsTextbox.TabIndex = 17; 128 | this.ColumnsTextbox.Text = "Columns"; 129 | this.ColumnsTextbox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; 130 | // 131 | // RowsTextbox 132 | // 133 | this.RowsTextbox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 134 | this.RowsTextbox.BorderStyle = System.Windows.Forms.BorderStyle.None; 135 | this.RowsTextbox.Cursor = System.Windows.Forms.Cursors.IBeam; 136 | this.RowsTextbox.Font = new System.Drawing.Font("Gadugi", 20F); 137 | this.RowsTextbox.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(178)))), ((int)(((byte)(178)))), ((int)(((byte)(178))))); 138 | this.RowsTextbox.Location = new System.Drawing.Point(225, 108); 139 | this.RowsTextbox.Name = "RowsTextbox"; 140 | this.RowsTextbox.Size = new System.Drawing.Size(136, 36); 141 | this.RowsTextbox.TabIndex = 16; 142 | this.RowsTextbox.Text = "Rows"; 143 | this.RowsTextbox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; 144 | // 145 | // Title2 146 | // 147 | this.Title2.Anchor = System.Windows.Forms.AnchorStyles.Top; 148 | this.Title2.AutoSize = true; 149 | this.Title2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 150 | this.Title2.Cursor = System.Windows.Forms.Cursors.Default; 151 | this.Title2.Font = new System.Drawing.Font("Gadugi", 18F); 152 | this.Title2.ForeColor = System.Drawing.Color.White; 153 | this.Title2.Location = new System.Drawing.Point(210, 61); 154 | this.Title2.Name = "Title2"; 155 | this.Title2.Size = new System.Drawing.Size(186, 28); 156 | this.Title2.TabIndex = 18; 157 | this.Title2.Text = "Flipbook Format"; 158 | this.Title2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 159 | // 160 | // DissectForm 161 | // 162 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 163 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 164 | this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 165 | this.ClientSize = new System.Drawing.Size(402, 298); 166 | this.Controls.Add(this.Title2); 167 | this.Controls.Add(this.ColumnsTextbox); 168 | this.Controls.Add(this.RowsTextbox); 169 | this.Controls.Add(this.CloseButton); 170 | this.Controls.Add(this.Title); 171 | this.Controls.Add(this.DissectButton); 172 | this.Controls.Add(this.ImportButton); 173 | this.Controls.Add(this.ImageFrame); 174 | this.Cursor = System.Windows.Forms.Cursors.Default; 175 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; 176 | this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); 177 | this.Name = "DissectForm"; 178 | this.Text = "DissectForm"; 179 | ((System.ComponentModel.ISupportInitialize)(this.ImageFrame)).EndInit(); 180 | this.ResumeLayout(false); 181 | this.PerformLayout(); 182 | 183 | } 184 | 185 | #endregion 186 | 187 | private System.Windows.Forms.PictureBox ImageFrame; 188 | private System.Windows.Forms.Button ImportButton; 189 | private System.Windows.Forms.Button DissectButton; 190 | private System.Windows.Forms.Label Title; 191 | private System.Windows.Forms.Button CloseButton; 192 | private System.Windows.Forms.TextBox ColumnsTextbox; 193 | private System.Windows.Forms.TextBox RowsTextbox; 194 | private System.Windows.Forms.Label Title2; 195 | } 196 | } -------------------------------------------------------------------------------- /FlipbookTool/ResizeForm.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace FlipbookTool 3 | { 4 | partial class ResizeForm 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ResizeForm)); 33 | this.Title = new System.Windows.Forms.Label(); 34 | this.CloseButton = new System.Windows.Forms.Button(); 35 | this.ImportButton = new System.Windows.Forms.Button(); 36 | this.ExportButton = new System.Windows.Forms.Button(); 37 | this.ImageFrame = new System.Windows.Forms.PictureBox(); 38 | this.Title2 = new System.Windows.Forms.Label(); 39 | this.WidthTextbox = new System.Windows.Forms.TextBox(); 40 | this.HeightTextbox = new System.Windows.Forms.TextBox(); 41 | this.panel1 = new System.Windows.Forms.Panel(); 42 | this.panel2 = new System.Windows.Forms.Panel(); 43 | this.panel3 = new System.Windows.Forms.Panel(); 44 | ((System.ComponentModel.ISupportInitialize)(this.ImageFrame)).BeginInit(); 45 | this.SuspendLayout(); 46 | // 47 | // Title 48 | // 49 | this.Title.Anchor = System.Windows.Forms.AnchorStyles.Top; 50 | this.Title.AutoSize = true; 51 | this.Title.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 52 | this.Title.Cursor = System.Windows.Forms.Cursors.Default; 53 | this.Title.Font = new System.Drawing.Font("Gadugi", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 54 | this.Title.ForeColor = System.Drawing.Color.White; 55 | this.Title.Location = new System.Drawing.Point(7, 12); 56 | this.Title.Name = "Title"; 57 | this.Title.Size = new System.Drawing.Size(148, 31); 58 | this.Title.TabIndex = 1; 59 | this.Title.Text = "Resize Tool"; 60 | this.Title.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 61 | // 62 | // CloseButton 63 | // 64 | this.CloseButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 65 | this.CloseButton.Cursor = System.Windows.Forms.Cursors.Hand; 66 | this.CloseButton.FlatAppearance.BorderSize = 0; 67 | this.CloseButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 68 | this.CloseButton.Font = new System.Drawing.Font("Comic Sans MS", 14F); 69 | this.CloseButton.ForeColor = System.Drawing.Color.White; 70 | this.CloseButton.ImageAlign = System.Drawing.ContentAlignment.TopCenter; 71 | this.CloseButton.Location = new System.Drawing.Point(355, 7); 72 | this.CloseButton.Name = "CloseButton"; 73 | this.CloseButton.Size = new System.Drawing.Size(40, 40); 74 | this.CloseButton.TabIndex = 5; 75 | this.CloseButton.Text = "X"; 76 | this.CloseButton.UseVisualStyleBackColor = false; 77 | // 78 | // ImportButton 79 | // 80 | this.ImportButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 81 | this.ImportButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 82 | this.ImportButton.Cursor = System.Windows.Forms.Cursors.Hand; 83 | this.ImportButton.FlatAppearance.BorderSize = 0; 84 | this.ImportButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 85 | this.ImportButton.Font = new System.Drawing.Font("Gadugi", 18F); 86 | this.ImportButton.ForeColor = System.Drawing.Color.White; 87 | this.ImportButton.Location = new System.Drawing.Point(12, 246); 88 | this.ImportButton.Name = "ImportButton"; 89 | this.ImportButton.Size = new System.Drawing.Size(186, 42); 90 | this.ImportButton.TabIndex = 6; 91 | this.ImportButton.Text = "Import"; 92 | this.ImportButton.UseVisualStyleBackColor = false; 93 | // 94 | // ExportButton 95 | // 96 | this.ExportButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 97 | this.ExportButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 98 | this.ExportButton.Cursor = System.Windows.Forms.Cursors.Hand; 99 | this.ExportButton.FlatAppearance.BorderSize = 0; 100 | this.ExportButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 101 | this.ExportButton.Font = new System.Drawing.Font("Gadugi", 18F); 102 | this.ExportButton.ForeColor = System.Drawing.Color.White; 103 | this.ExportButton.Location = new System.Drawing.Point(204, 246); 104 | this.ExportButton.Name = "ExportButton"; 105 | this.ExportButton.Size = new System.Drawing.Size(186, 42); 106 | this.ExportButton.TabIndex = 7; 107 | this.ExportButton.Text = "Export"; 108 | this.ExportButton.UseVisualStyleBackColor = false; 109 | // 110 | // ImageFrame 111 | // 112 | this.ImageFrame.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 113 | this.ImageFrame.Location = new System.Drawing.Point(13, 54); 114 | this.ImageFrame.Name = "ImageFrame"; 115 | this.ImageFrame.Size = new System.Drawing.Size(186, 186); 116 | this.ImageFrame.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; 117 | this.ImageFrame.TabIndex = 8; 118 | this.ImageFrame.TabStop = false; 119 | // 120 | // Title2 121 | // 122 | this.Title2.Anchor = System.Windows.Forms.AnchorStyles.Top; 123 | this.Title2.AutoSize = true; 124 | this.Title2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 125 | this.Title2.Cursor = System.Windows.Forms.Cursors.Default; 126 | this.Title2.Font = new System.Drawing.Font("Gadugi", 18F); 127 | this.Title2.ForeColor = System.Drawing.Color.White; 128 | this.Title2.Location = new System.Drawing.Point(210, 54); 129 | this.Title2.Name = "Title2"; 130 | this.Title2.Size = new System.Drawing.Size(180, 28); 131 | this.Title2.TabIndex = 9; 132 | this.Title2.Text = "New Resolution"; 133 | this.Title2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 134 | // 135 | // WidthTextbox 136 | // 137 | this.WidthTextbox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 138 | this.WidthTextbox.BorderStyle = System.Windows.Forms.BorderStyle.None; 139 | this.WidthTextbox.Cursor = System.Windows.Forms.Cursors.IBeam; 140 | this.WidthTextbox.Font = new System.Drawing.Font("Gadugi", 20F); 141 | this.WidthTextbox.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(178)))), ((int)(((byte)(178)))), ((int)(((byte)(178))))); 142 | this.WidthTextbox.Location = new System.Drawing.Point(215, 101); 143 | this.WidthTextbox.Name = "WidthTextbox"; 144 | this.WidthTextbox.Size = new System.Drawing.Size(136, 36); 145 | this.WidthTextbox.TabIndex = 10; 146 | this.WidthTextbox.Text = "Width"; 147 | this.WidthTextbox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; 148 | // 149 | // HeightTextbox 150 | // 151 | this.HeightTextbox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 152 | this.HeightTextbox.BorderStyle = System.Windows.Forms.BorderStyle.None; 153 | this.HeightTextbox.Cursor = System.Windows.Forms.Cursors.No; 154 | this.HeightTextbox.Font = new System.Drawing.Font("Gadugi", 20F); 155 | this.HeightTextbox.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(178)))), ((int)(((byte)(178)))), ((int)(((byte)(178))))); 156 | this.HeightTextbox.Location = new System.Drawing.Point(215, 172); 157 | this.HeightTextbox.Name = "HeightTextbox"; 158 | this.HeightTextbox.ReadOnly = true; 159 | this.HeightTextbox.Size = new System.Drawing.Size(136, 36); 160 | this.HeightTextbox.TabIndex = 11; 161 | this.HeightTextbox.Text = "Height"; 162 | this.HeightTextbox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; 163 | // 164 | // panel1 165 | // 166 | this.panel1.BackColor = System.Drawing.Color.White; 167 | this.panel1.Location = new System.Drawing.Point(357, 120); 168 | this.panel1.Name = "panel1"; 169 | this.panel1.Size = new System.Drawing.Size(19, 3); 170 | this.panel1.TabIndex = 12; 171 | // 172 | // panel2 173 | // 174 | this.panel2.BackColor = System.Drawing.Color.White; 175 | this.panel2.Location = new System.Drawing.Point(357, 191); 176 | this.panel2.Name = "panel2"; 177 | this.panel2.Size = new System.Drawing.Size(19, 3); 178 | this.panel2.TabIndex = 13; 179 | // 180 | // panel3 181 | // 182 | this.panel3.BackColor = System.Drawing.Color.White; 183 | this.panel3.Location = new System.Drawing.Point(373, 123); 184 | this.panel3.Name = "panel3"; 185 | this.panel3.Size = new System.Drawing.Size(3, 70); 186 | this.panel3.TabIndex = 13; 187 | // 188 | // ResizeForm 189 | // 190 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 191 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 192 | this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 193 | this.ClientSize = new System.Drawing.Size(402, 298); 194 | this.Controls.Add(this.panel3); 195 | this.Controls.Add(this.panel2); 196 | this.Controls.Add(this.panel1); 197 | this.Controls.Add(this.HeightTextbox); 198 | this.Controls.Add(this.WidthTextbox); 199 | this.Controls.Add(this.Title2); 200 | this.Controls.Add(this.ImageFrame); 201 | this.Controls.Add(this.ExportButton); 202 | this.Controls.Add(this.ImportButton); 203 | this.Controls.Add(this.CloseButton); 204 | this.Controls.Add(this.Title); 205 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; 206 | this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); 207 | this.Name = "ResizeForm"; 208 | this.Text = "ResizeForm"; 209 | ((System.ComponentModel.ISupportInitialize)(this.ImageFrame)).EndInit(); 210 | this.ResumeLayout(false); 211 | this.PerformLayout(); 212 | 213 | } 214 | 215 | #endregion 216 | 217 | private System.Windows.Forms.Label Title; 218 | private System.Windows.Forms.Button CloseButton; 219 | private System.Windows.Forms.Button ImportButton; 220 | private System.Windows.Forms.Button ExportButton; 221 | private System.Windows.Forms.PictureBox ImageFrame; 222 | private System.Windows.Forms.Label Title2; 223 | private System.Windows.Forms.TextBox WidthTextbox; 224 | private System.Windows.Forms.TextBox HeightTextbox; 225 | private System.Windows.Forms.Panel panel1; 226 | private System.Windows.Forms.Panel panel2; 227 | private System.Windows.Forms.Panel panel3; 228 | } 229 | } -------------------------------------------------------------------------------- /FlipbookTool/PreviewForm.Designer.cs: -------------------------------------------------------------------------------- 1 | 2 | namespace FlipbookTool 3 | { 4 | partial class PreviewForm 5 | { 6 | /// 7 | /// Required designer variable. 8 | /// 9 | private System.ComponentModel.IContainer components = null; 10 | 11 | /// 12 | /// Clean up any resources being used. 13 | /// 14 | /// true if managed resources should be disposed; otherwise, false. 15 | protected override void Dispose(bool disposing) 16 | { 17 | if (disposing && (components != null)) 18 | { 19 | components.Dispose(); 20 | } 21 | base.Dispose(disposing); 22 | } 23 | 24 | #region Windows Form Designer generated code 25 | 26 | /// 27 | /// Required method for Designer support - do not modify 28 | /// the contents of this method with the code editor. 29 | /// 30 | private void InitializeComponent() 31 | { 32 | System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(PreviewForm)); 33 | this.Title = new System.Windows.Forms.Label(); 34 | this.CloseButton = new System.Windows.Forms.Button(); 35 | this.ImageFrame = new System.Windows.Forms.PictureBox(); 36 | this.ImportButton = new System.Windows.Forms.Button(); 37 | this.Title2 = new System.Windows.Forms.Label(); 38 | this.ColumnsTextbox = new System.Windows.Forms.TextBox(); 39 | this.RowsTextbox = new System.Windows.Forms.TextBox(); 40 | this.SecondsTextbox = new System.Windows.Forms.TextBox(); 41 | this.OutputFrame = new System.Windows.Forms.PictureBox(); 42 | this.PlayButton = new System.Windows.Forms.Button(); 43 | ((System.ComponentModel.ISupportInitialize)(this.ImageFrame)).BeginInit(); 44 | ((System.ComponentModel.ISupportInitialize)(this.OutputFrame)).BeginInit(); 45 | this.SuspendLayout(); 46 | // 47 | // Title 48 | // 49 | this.Title.Anchor = System.Windows.Forms.AnchorStyles.Top; 50 | this.Title.AutoSize = true; 51 | this.Title.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 52 | this.Title.Cursor = System.Windows.Forms.Cursors.Default; 53 | this.Title.Font = new System.Drawing.Font("Gadugi", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); 54 | this.Title.ForeColor = System.Drawing.Color.White; 55 | this.Title.Location = new System.Drawing.Point(10, 15); 56 | this.Title.Name = "Title"; 57 | this.Title.Size = new System.Drawing.Size(166, 31); 58 | this.Title.TabIndex = 15; 59 | this.Title.Text = "Preview Tool"; 60 | this.Title.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 61 | // 62 | // CloseButton 63 | // 64 | this.CloseButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 65 | this.CloseButton.Cursor = System.Windows.Forms.Cursors.Hand; 66 | this.CloseButton.FlatAppearance.BorderSize = 0; 67 | this.CloseButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 68 | this.CloseButton.Font = new System.Drawing.Font("Comic Sans MS", 14F); 69 | this.CloseButton.ForeColor = System.Drawing.Color.White; 70 | this.CloseButton.ImageAlign = System.Drawing.ContentAlignment.TopCenter; 71 | this.CloseButton.Location = new System.Drawing.Point(581, 7); 72 | this.CloseButton.Name = "CloseButton"; 73 | this.CloseButton.Size = new System.Drawing.Size(40, 40); 74 | this.CloseButton.TabIndex = 16; 75 | this.CloseButton.Text = "X"; 76 | this.CloseButton.UseVisualStyleBackColor = false; 77 | // 78 | // ImageFrame 79 | // 80 | this.ImageFrame.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 81 | this.ImageFrame.Location = new System.Drawing.Point(12, 59); 82 | this.ImageFrame.Name = "ImageFrame"; 83 | this.ImageFrame.Size = new System.Drawing.Size(186, 186); 84 | this.ImageFrame.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; 85 | this.ImageFrame.TabIndex = 17; 86 | this.ImageFrame.TabStop = false; 87 | // 88 | // ImportButton 89 | // 90 | this.ImportButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 91 | this.ImportButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 92 | this.ImportButton.Cursor = System.Windows.Forms.Cursors.Hand; 93 | this.ImportButton.FlatAppearance.BorderSize = 0; 94 | this.ImportButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 95 | this.ImportButton.Font = new System.Drawing.Font("Gadugi", 18F); 96 | this.ImportButton.ForeColor = System.Drawing.Color.White; 97 | this.ImportButton.Location = new System.Drawing.Point(12, 251); 98 | this.ImportButton.Name = "ImportButton"; 99 | this.ImportButton.Size = new System.Drawing.Size(186, 42); 100 | this.ImportButton.TabIndex = 18; 101 | this.ImportButton.Text = "Import"; 102 | this.ImportButton.UseVisualStyleBackColor = false; 103 | // 104 | // Title2 105 | // 106 | this.Title2.Anchor = System.Windows.Forms.AnchorStyles.Top; 107 | this.Title2.AutoSize = true; 108 | this.Title2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 109 | this.Title2.Cursor = System.Windows.Forms.Cursors.Default; 110 | this.Title2.Font = new System.Drawing.Font("Gadugi", 18F); 111 | this.Title2.ForeColor = System.Drawing.Color.White; 112 | this.Title2.Location = new System.Drawing.Point(218, 59); 113 | this.Title2.Name = "Title2"; 114 | this.Title2.Size = new System.Drawing.Size(186, 28); 115 | this.Title2.TabIndex = 21; 116 | this.Title2.Text = "Flipbook Format"; 117 | this.Title2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; 118 | // 119 | // ColumnsTextbox 120 | // 121 | this.ColumnsTextbox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 122 | this.ColumnsTextbox.BorderStyle = System.Windows.Forms.BorderStyle.None; 123 | this.ColumnsTextbox.Cursor = System.Windows.Forms.Cursors.Default; 124 | this.ColumnsTextbox.Font = new System.Drawing.Font("Gadugi", 20F); 125 | this.ColumnsTextbox.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(178)))), ((int)(((byte)(178)))), ((int)(((byte)(178))))); 126 | this.ColumnsTextbox.Location = new System.Drawing.Point(236, 178); 127 | this.ColumnsTextbox.Name = "ColumnsTextbox"; 128 | this.ColumnsTextbox.Size = new System.Drawing.Size(136, 36); 129 | this.ColumnsTextbox.TabIndex = 20; 130 | this.ColumnsTextbox.Text = "Columns"; 131 | this.ColumnsTextbox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; 132 | // 133 | // RowsTextbox 134 | // 135 | this.RowsTextbox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 136 | this.RowsTextbox.BorderStyle = System.Windows.Forms.BorderStyle.None; 137 | this.RowsTextbox.Cursor = System.Windows.Forms.Cursors.IBeam; 138 | this.RowsTextbox.Font = new System.Drawing.Font("Gadugi", 20F); 139 | this.RowsTextbox.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(178)))), ((int)(((byte)(178)))), ((int)(((byte)(178))))); 140 | this.RowsTextbox.Location = new System.Drawing.Point(236, 127); 141 | this.RowsTextbox.Name = "RowsTextbox"; 142 | this.RowsTextbox.Size = new System.Drawing.Size(136, 36); 143 | this.RowsTextbox.TabIndex = 19; 144 | this.RowsTextbox.Text = "Rows"; 145 | this.RowsTextbox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; 146 | // 147 | // SecondsTextbox 148 | // 149 | this.SecondsTextbox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 150 | this.SecondsTextbox.BorderStyle = System.Windows.Forms.BorderStyle.None; 151 | this.SecondsTextbox.Cursor = System.Windows.Forms.Cursors.Default; 152 | this.SecondsTextbox.Font = new System.Drawing.Font("Gadugi", 20F); 153 | this.SecondsTextbox.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(178)))), ((int)(((byte)(178)))), ((int)(((byte)(178))))); 154 | this.SecondsTextbox.Location = new System.Drawing.Point(236, 229); 155 | this.SecondsTextbox.Name = "SecondsTextbox"; 156 | this.SecondsTextbox.Size = new System.Drawing.Size(136, 36); 157 | this.SecondsTextbox.TabIndex = 22; 158 | this.SecondsTextbox.Text = "Seconds"; 159 | this.SecondsTextbox.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; 160 | // 161 | // OutputFrame 162 | // 163 | this.OutputFrame.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; 164 | this.OutputFrame.Location = new System.Drawing.Point(431, 59); 165 | this.OutputFrame.Name = "OutputFrame"; 166 | this.OutputFrame.Size = new System.Drawing.Size(186, 186); 167 | this.OutputFrame.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage; 168 | this.OutputFrame.TabIndex = 23; 169 | this.OutputFrame.TabStop = false; 170 | // 171 | // PlayButton 172 | // 173 | this.PlayButton.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); 174 | this.PlayButton.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None; 175 | this.PlayButton.Cursor = System.Windows.Forms.Cursors.Hand; 176 | this.PlayButton.FlatAppearance.BorderSize = 0; 177 | this.PlayButton.FlatStyle = System.Windows.Forms.FlatStyle.Flat; 178 | this.PlayButton.Font = new System.Drawing.Font("Gadugi", 18F); 179 | this.PlayButton.ForeColor = System.Drawing.Color.White; 180 | this.PlayButton.Location = new System.Drawing.Point(431, 251); 181 | this.PlayButton.Name = "PlayButton"; 182 | this.PlayButton.Size = new System.Drawing.Size(186, 42); 183 | this.PlayButton.TabIndex = 24; 184 | this.PlayButton.Text = "Play"; 185 | this.PlayButton.UseVisualStyleBackColor = false; 186 | // 187 | // PreviewForm 188 | // 189 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 190 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 191 | this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20))))); 192 | this.ClientSize = new System.Drawing.Size(627, 304); 193 | this.Controls.Add(this.PlayButton); 194 | this.Controls.Add(this.OutputFrame); 195 | this.Controls.Add(this.SecondsTextbox); 196 | this.Controls.Add(this.Title2); 197 | this.Controls.Add(this.ColumnsTextbox); 198 | this.Controls.Add(this.RowsTextbox); 199 | this.Controls.Add(this.ImportButton); 200 | this.Controls.Add(this.ImageFrame); 201 | this.Controls.Add(this.CloseButton); 202 | this.Controls.Add(this.Title); 203 | this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None; 204 | this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); 205 | this.Name = "PreviewForm"; 206 | this.Text = "PreviewForm"; 207 | ((System.ComponentModel.ISupportInitialize)(this.ImageFrame)).EndInit(); 208 | ((System.ComponentModel.ISupportInitialize)(this.OutputFrame)).EndInit(); 209 | this.ResumeLayout(false); 210 | this.PerformLayout(); 211 | 212 | } 213 | 214 | #endregion 215 | 216 | private System.Windows.Forms.Label Title; 217 | private System.Windows.Forms.Button CloseButton; 218 | private System.Windows.Forms.PictureBox ImageFrame; 219 | private System.Windows.Forms.Button ImportButton; 220 | private System.Windows.Forms.Label Title2; 221 | private System.Windows.Forms.TextBox ColumnsTextbox; 222 | private System.Windows.Forms.TextBox RowsTextbox; 223 | private System.Windows.Forms.TextBox SecondsTextbox; 224 | private System.Windows.Forms.PictureBox OutputFrame; 225 | private System.Windows.Forms.Button PlayButton; 226 | } 227 | } --------------------------------------------------------------------------------