public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.AddProject <ProjectNetImguiServer>(target); SolutionSample.AddSampleProjects(conf, target); Utility.AddCompatibilityProjects(conf, target); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.AddPublicDependency <ProjectImgui>(target); conf.IncludePaths.Add(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath)); conf.IncludePaths.Add(NetImguiTarget.GetPath(@"\Code\Client")); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.Options.Add(Options.Vc.General.WarningLevel.EnableAllWarnings); conf.IncludePaths.Add(@"[project.SharpmakeCsPath]\..\Code\ThirdParty\" + mVersion); conf.LibraryFiles.Add("ws2_32.lib"); }
public void ConfigureAll(Configuration conf, NetImguiTarget target) { conf.Name = @"[target.Compiler]_[target.Optimization]"; conf.ProjectFileName = @"[project.Name]"; conf.TargetFileSuffix = @"_[target.Optimization]"; conf.ProjectPath = @"[project.SharpmakeCsPath]\_Projects\[target.DevEnv]"; conf.TargetPath = mIsExe ? @"[project.SharpmakeCsPath]\_Bin\[target.Compiler]_[target.Platform]" : @"[project.SharpmakeCsPath]\_Lib\[target.Compiler]_[target.Platform]"; conf.IntermediatePath = @"[project.SharpmakeCsPath]\_Intermediate\[target.Compiler]_[target.Platform]_[target.Optimization]\[project.Name]"; conf.Output = mIsExe ? Project.Configuration.OutputType.Exe : Project.Configuration.OutputType.Lib; if (target.Compiler == Compiler.Clang) { conf.Options.Add(Options.Vc.General.PlatformToolset.LLVM); } if (mIsExe) { conf.VcxprojUserFile = new ProjConfig.VcxprojUserFileSettings(); conf.VcxprojUserFile.LocalDebuggerWorkingDirectory = "$(TargetDir)"; conf.Options.Add(Options.Vc.Linker.SubSystem.Application); conf.LibraryFiles.Add("D3D11.lib"); } conf.Options.Add(Options.Vc.General.TreatWarningsAsErrors.Enable); conf.Options.Add(Options.Vc.General.CharacterSet.Unicode); conf.Options.Add(Options.Vc.Linker.TreatLinkerWarningAsErrors.Enable); //conf.Options.Add(new Options.Vc.Compiler.DisableSpecificWarnings("")); //conf.Options.Add(Options.Vc.Librarian.TreatLibWarningAsErrors.Enable); //Note: VisualStudio 2019 doesn't support this option properly }
// Add sources files for platform specific Dear ImGui backend (OS/Renderer support) public void AddImguiBackendSources() { SourceFiles.Add(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath) + @"\backends\imgui_impl_dx11.h"); SourceFiles.Add(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath) + @"\backends\imgui_impl_dx11.cpp"); SourceFiles.Add(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath) + @"\backends\imgui_impl_win32.h"); SourceFiles.Add(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath) + @"\backends\imgui_impl_win32.cpp"); }
public ProjectImgui() : base(false) { Name = "DearImgui"; SourceRootPath = NetImguiTarget.GetPath(sDefaultPath); SourceFilesExcludeRegex.Add(@"backends\.*"); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.Options.Add(Options.Vc.General.WarningLevel.EnableAllWarnings); conf.IncludePaths.Add(mImguiPath); conf.LibraryFiles.Add("ws2_32.lib"); }
public ProjectSample_SingleInclude() : base(true) { Name = "SampleSingleInclude"; SourceRootPath = NetImguiTarget.GetPath(@"\Code\Sample\") + Name; AdditionalSourceRootPaths.Add(NetImguiTarget.GetPath(@"\Code\Sample\Common")); AddImguiBackendSources(); }
public ProjectSample(string inName) : base(true) { Name = inName; SourceRootPath = NetImguiTarget.GetPath(@"\Code\Sample\") + Name; AdditionalSourceRootPaths.Add(NetImguiTarget.GetPath(@"\Code\Sample\Common")); AddImguiBackendSources(); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.AddPublicDependency <ProjectImgui_Default>(target); conf.AddPublicDependency <ProjectNetImgui_Default>(target); conf.IncludePaths.Add(@"[project.SharpmakeCsPath]\..\Code\ThirdParty\" + SolutionAll.sDefaultImguiVersion); conf.IncludePaths.Add(@"[project.SharpmakeCsPath]\..\Code\Client"); }
public ProjectNetImgui(string imguiFullPath) : base(false) { mVersion = Path.GetFileName(imguiFullPath); mImguiPath = imguiFullPath; Name = "NetImguiLib (" + mVersion + ")"; SourceRootPath = NetImguiTarget.GetPath(@"\Code\Client"); SourceFiles.Add(mImguiPath + @"\imgui.h"); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.AddPublicDependency <ProjectImgui>(target); conf.AddPublicDependency <ProjectNetImgui_Disabled>(target); conf.IncludePaths.Add(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath)); conf.IncludePaths.Add(NetImguiTarget.GetPath(@"\Code\Client")); conf.Defines.Add("NETIMGUI_ENABLED=0"); }
public static void AddProjects(Configuration conf, NetImguiTarget target) { string SolutionFolder = @"Samples"; conf.AddProject <ProjectSample_Basic>(target, false, SolutionFolder); conf.AddProject <ProjectSample_NewFrame>(target, false, SolutionFolder); conf.AddProject <ProjectSample_DualUI>(target, false, SolutionFolder); conf.AddProject <ProjectSample_Textures>(target, false, SolutionFolder); conf.AddProject <ProjectSample_Disabled>(target, false, SolutionFolder); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.AddProject <ProjectNetImguiServer>(target); conf.AddProject <ProjectSample>(target); conf.AddProject <ProjectNetImgui_17500>(target, false, "Compatibility Tests"); conf.AddProject <ProjectNetImgui_17600>(target, false, "Compatibility Tests"); conf.AddProject <ProjectNetImgui_Dock17601>(target, false, "Compatibility Tests"); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.AddPublicDependency <ProjectImgui_Default>(target); conf.AddPublicDependency <ProjectNetImgui_Default>(target); conf.IncludePaths.Add(SourceRootPath + @"\Source"); conf.IncludePaths.Add(@"[project.SharpmakeCsPath]\..\Code\ThirdParty\" + SolutionAll.sDefaultImguiVersion); conf.IncludePaths.Add(@"[project.SharpmakeCsPath]\..\Code\Client"); conf.EventPostBuild.Add(@"xcopy [project.SharpmakeCsPath]\..\Code\ServerApp\Background.png " + conf.TargetPath + " /D /Y"); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.AddPublicDependency <ProjectImgui>(target); conf.AddPublicDependency <ProjectNetImgui_Default>(target); conf.IncludePaths.Add(SourceRootPath + @"\Source"); conf.IncludePaths.Add(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath)); conf.IncludePaths.Add(NetImguiTarget.GetPath(@"\Code\Client")); conf.EventPostBuild.Add(@"xcopy " + NetImguiTarget.GetPath(@"\Code\ServerApp\Background.png") + " " + conf.TargetPath + " /D /Y"); }
public ProjectNetImguiServer() : base(true) { Name = "NetImguiServer"; SourceRootPath = NetImguiTarget.GetPath(@"\Code\ServerApp"); ResourceFiles.Add(NetImguiTarget.GetPath(@"\Code\ServerApp\small.ico")); ResourceFiles.Add(NetImguiTarget.GetPath(@"\Code\ServerApp\netImguiApp.ico")); ResourceFiles.Add(NetImguiTarget.GetPath(@"\Code\ServerApp\netImguiApp.rc")); ResourceFiles.Add(NetImguiTarget.GetPath(@"\Code\ServerApp\Background.png")); SourceFilesBuildExcludeRegex.Add(@".*Code\\ServerApp\\Source\\Fonts\\.*"); AddImguiBackendSources(); }
public static void AddSampleProjects(Configuration conf, NetImguiTarget target) { string SolutionFolder = "Samples"; conf.AddProject <ProjectSample_Basic>(target, false, SolutionFolder); conf.AddProject <ProjectSample_NewFrame>(target, false, SolutionFolder); conf.AddProject <ProjectSample_DualUI>(target, false, SolutionFolder); conf.AddProject <ProjectSample_Textures>(target, false, SolutionFolder); conf.AddProject <ProjectSample_Background>(target, false, SolutionFolder); conf.AddProject <ProjectSample_Disabled>(target, false, SolutionFolder); conf.AddProject <ProjectSample_SingleInclude>(target, false, SolutionFolder); // Adding an already auto included dependcy, so it can be moved to more appropriate folder conf.AddProject <ProjectNetImgui_Disabled>(target, false, "CompatibilityTest"); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.AddProject <ProjectNetImguiServer>(target); SolutionSample.AddProjects(conf, target); string SolutionFolder = @"Compatibility Tests"; conf.AddProject <ProjectNetImgui_17400>(target, false, SolutionFolder); conf.AddProject <ProjectNetImgui_17500>(target, false, SolutionFolder); conf.AddProject <ProjectNetImgui_17600>(target, false, SolutionFolder); conf.AddProject <ProjectNetImgui_17700>(target, false, SolutionFolder); conf.AddProject <ProjectNetImgui_17800>(target, false, SolutionFolder); conf.AddProject <ProjectNetImgui_Dock17601>(target, false, SolutionFolder); conf.AddProject <ProjectNetImgui_Disabled>(target, false, SolutionFolder); }
public static void ClaimShaderFiles(Project project, string filenameEnding, ShaderProfile shaderProfile, string entryName) { Strings hlsl_Files = new Strings(project.ResolvedSourceFiles.Where(file => file.EndsWith(filenameEnding, StringComparison.InvariantCultureIgnoreCase))); if (hlsl_Files.Count() > 0) { foreach (ProjConfig conf in project.Configurations) { string targetName = conf.Target.Name; string outputDir = string.Format(@"{0}\{1}_{2}\", NetImguiTarget.GetPath(@"\_generated\Shaders"), project.Name, conf.Target.GetOptimization()); conf.IncludePaths.Add(outputDir); foreach (string file in hlsl_Files) { CustomBuildFileHLSL HlslCompileTask = new CustomBuildFileHLSL(conf, targetName, shaderProfile, entryName, outputDir, Project.GetCapitalizedFile(file)); project.ResolvedSourceFiles.Add(HlslCompileTask.Output); conf.CustomFileBuildSteps.Add(HlslCompileTask); } } } }
public void ConfigureAll(Configuration conf, NetImguiTarget target) { conf.Name = @"[target.Compiler]_[target.Optimization]"; conf.ProjectFileName = @"[project.Name]"; conf.TargetFileSuffix = @"_[target.Optimization]"; conf.ProjectPath = NetImguiTarget.GetPath(@"\_projects\[target.DevEnv]"); conf.TargetPath = NetImguiTarget.GetPath(mIsExe ? @"\_Bin\[target.DevEnv]_[target.Compiler]_[target.Platform]" : @"\_generated\Libs\[target.DevEnv]_[target.Compiler]_[target.Platform]"); conf.IntermediatePath = NetImguiTarget.GetPath(@"\_intermediate\[target.DevEnv]_[target.Compiler]_[target.Platform]_[target.Optimization]\[project.Name]"); conf.Output = mIsExe ? Project.Configuration.OutputType.Exe : Project.Configuration.OutputType.Lib; conf.IncludePaths.Add(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath) + @"\backends"); if (target.Compiler == Compiler.Clang) { conf.Options.Add(Options.Vc.General.PlatformToolset.ClangCL); } if (mIsExe) { conf.VcxprojUserFile = new ProjConfig.VcxprojUserFileSettings(); conf.VcxprojUserFile.LocalDebuggerWorkingDirectory = "$(TargetDir)"; conf.Options.Add(Options.Vc.Linker.SubSystem.Application); conf.LibraryFiles.Add("D3D11.lib"); conf.IncludePaths.Add(NetImguiTarget.GetPath(@"\Code")); } conf.Options.Add(Options.Vc.General.WindowsTargetPlatformVersion.Latest); conf.Options.Add(Options.Vc.General.TreatWarningsAsErrors.Enable); conf.Options.Add(Options.Vc.General.CharacterSet.Unicode); conf.Options.Add(Options.Vc.Linker.TreatLinkerWarningAsErrors.Enable); conf.Defines.Add("_HAS_EXCEPTIONS=0"); // Prevents error in VisualStudio c++ library with NoExcept, like xlocale //conf.Options.Add(new Options.Vc.Compiler.DisableSpecificWarnings("")); //conf.Options.Add(Options.Vc.Librarian.TreatLibWarningAsErrors.Enable); //Note: VisualStudio 2019 doesn't support this option properly }
public ProjectNetImgui_Disabled() : base(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath)) { Name = "NetImguiLib (Disabled)"; }
public void ConfigureAll(Configuration conf, NetImguiTarget target) { conf.Name = "[target.Compiler]_[target.Optimization]"; conf.SolutionFileName = "[target.DevEnv]_[solution.Name]"; conf.SolutionPath = NetImguiTarget.GetPath(@"\_projects"); }
public void ConfigureAll(Configuration conf, NetImguiTarget target) { conf.Name = "[target.Compiler]_[target.Optimization]"; conf.SolutionFileName = "[target.DevEnv]_[solution.Name]"; conf.SolutionPath = @"[solution.SharpmakeCsPath]\_Projects"; }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); SolutionSample.AddSampleProjects(conf, target); }
//============================================================================================= // PROJECTS //============================================================================================= // Generate the default Imgui/netImgui Libraries (used to link against with Samples/Server) [Sharpmake.Generate] public class ProjectNetImgui_Default : ProjectNetImgui { public ProjectNetImgui_Default() : base(NetImguiTarget.GetPath(ProjectImgui.sDefaultPath)) { Name = "NetImguiLib"; }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.AddProject <ProjectNetImguiServer>(target); }
public new void ConfigureAll(Configuration conf, NetImguiTarget target) { base.ConfigureAll(conf, target); conf.Defines.Add("NETIMGUI_ENABLED=0"); }