Marko Pintera 11 роки тому
батько
коміт
f272125527

+ 2 - 2
BansheeEngine.sln

@@ -385,8 +385,8 @@ Global
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|Mixed Platforms.Build.0 = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|Mixed Platforms.Build.0 = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|Win32.ActiveCfg = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|Win32.ActiveCfg = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|Win32.Build.0 = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|Win32.Build.0 = Release|Win32
-		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|x64.ActiveCfg = Release|x64
-		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|x64.Build.0 = Release|x64
+		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|x64.ActiveCfg = DebugRelease|x64
+		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.DebugRelease|x64.Build.0 = DebugRelease|x64
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.Release|Any CPU.ActiveCfg = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.Release|Any CPU.ActiveCfg = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.Release|Mixed Platforms.ActiveCfg = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.Release|Mixed Platforms.ActiveCfg = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.Release|Mixed Platforms.Build.0 = Release|Win32
 		{4E02D5FE-5A98-49C1-93FD-DF841A9FA3DB}.Release|Mixed Platforms.Build.0 = Release|Win32

+ 5 - 5
BansheeEngine/Include/BsGUIMenu.h

@@ -143,6 +143,11 @@ namespace BansheeEngine
 		 * @param	localizedName	Localized string with the name.
 		 * @param	localizedName	Localized string with the name.
 		 */
 		 */
 		void setLocalizedName(const WString& menuItemLabel, const HString& localizedName);
 		void setLocalizedName(const WString& menuItemLabel, const HString& localizedName);
+
+		/**
+		 * @brief	Returns data used for initializing a drop down list, for all elements.
+		 */
+		GUIDropDownData getDropDownData() const;
 	protected:
 	protected:
 		/**
 		/**
 		 * @brief	Adds a menu item at the specified path, as a normal button or as a separator.
 		 * @brief	Adds a menu item at the specified path, as a normal button or as a separator.
@@ -154,11 +159,6 @@ namespace BansheeEngine
 		 */
 		 */
 		GUIDropDownData getDropDownDataInternal(const GUIMenuItem& menu) const;
 		GUIDropDownData getDropDownDataInternal(const GUIMenuItem& menu) const;
 
 
-		/**
-		 * @brief	Returns data used for initializing a drop down list, for all elements.
-		 */
-		GUIDropDownData getDropDownData() const;
-
 		GUIMenuItem mRootElement;
 		GUIMenuItem mRootElement;
 		UnorderedMap<WString, HString> mLocalizedEntryNames;
 		UnorderedMap<WString, HString> mLocalizedEntryNames;
 	};
 	};

+ 0 - 4
BansheeEngine/Source/BsGUIManager.cpp

@@ -340,8 +340,6 @@ namespace BansheeEngine
 		{
 		{
 			GUIRenderData& renderData = cachedMeshData.second;
 			GUIRenderData& renderData = cachedMeshData.second;
 
 
-			gProfilerCPU().beginSample("UM_A");
-
 			// Check if anything is dirty. If nothing is we can skip the update
 			// Check if anything is dirty. If nothing is we can skip the update
 			bool isDirty = renderData.isDirty;
 			bool isDirty = renderData.isDirty;
 			renderData.isDirty = false;
 			renderData.isDirty = false;
@@ -354,8 +352,6 @@ namespace BansheeEngine
 				}
 				}
 			}
 			}
 
 
-			gProfilerCPU().endSample("UM_A");
-
 			if(!isDirty)
 			if(!isDirty)
 				continue;
 				continue;
 
 

+ 0 - 15
BansheeEngine/Source/BsTextSprite.cpp

@@ -15,11 +15,7 @@ namespace BansheeEngine
 
 
 	void TextSprite::update(const TEXT_SPRITE_DESC& desc)
 	void TextSprite::update(const TEXT_SPRITE_DESC& desc)
 	{
 	{
-		gProfilerCPU().beginSample("textUpdateA");
 		TextData textData(desc.text, desc.font, desc.fontSize, desc.width, desc.height, desc.wordWrap);
 		TextData textData(desc.text, desc.font, desc.fontSize, desc.width, desc.height, desc.wordWrap);
-		gProfilerCPU().endSample("textUpdateA");
-
-		gProfilerCPU().beginSample("textUpdateB");
 
 
 		UINT32 numLines = textData.getNumLines();
 		UINT32 numLines = textData.getNumLines();
 		UINT32 numPages = textData.getNumPages();
 		UINT32 numPages = textData.getNumPages();
@@ -53,9 +49,6 @@ namespace BansheeEngine
 		if(mCachedRenderElements.size() != numPages)
 		if(mCachedRenderElements.size() != numPages)
 			mCachedRenderElements.resize(numPages);
 			mCachedRenderElements.resize(numPages);
 
 
-		gProfilerCPU().endSample("textUpdateB");
-		gProfilerCPU().beginSample("textUpdateC");
-
 		// Actually generate a mesh
 		// Actually generate a mesh
 		UINT32 texPage = 0;
 		UINT32 texPage = 0;
 		for(auto& cachedElem : mCachedRenderElements)
 		for(auto& cachedElem : mCachedRenderElements)
@@ -104,9 +97,6 @@ namespace BansheeEngine
 			texPage++;
 			texPage++;
 		}
 		}
 
 
-		gProfilerCPU().instance().endSample("textUpdateC");
-		gProfilerCPU().instance().beginSample("textUpdateD");
-
 		// Calc alignment and anchor offsets and set final line positions
 		// Calc alignment and anchor offsets and set final line positions
 		for(UINT32 j = 0; j < numPages; j++)
 		for(UINT32 j = 0; j < numPages; j++)
 		{
 		{
@@ -116,12 +106,7 @@ namespace BansheeEngine
 				renderElem.vertices, renderElem.uvs, renderElem.indexes, renderElem.numQuads);
 				renderElem.vertices, renderElem.uvs, renderElem.indexes, renderElem.numQuads);
 		}
 		}
 
 
-		gProfilerCPU().instance().endSample("textUpdateD");
-		gProfilerCPU().instance().beginSample("textUpdateE");
-
 		updateBounds();
 		updateBounds();
-
-		gProfilerCPU().instance().endSample("textUpdateE");
 	}
 	}
 
 
 	UINT32 TextSprite::genTextQuads(UINT32 page, const TextData& textData, UINT32 width, UINT32 height, 
 	UINT32 TextSprite::genTextQuads(UINT32 page, const TextData& textData, UINT32 width, UINT32 height, 

+ 77 - 1
ExampleProject/ExampleProject.vcxproj

@@ -1,6 +1,14 @@
 <?xml version="1.0" encoding="utf-8"?>
 <?xml version="1.0" encoding="utf-8"?>
 <Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
 <Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
   <ItemGroup Label="ProjectConfigurations">
   <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="DebugRelease|Win32">
+      <Configuration>DebugRelease</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+    <ProjectConfiguration Include="DebugRelease|x64">
+      <Configuration>DebugRelease</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
     <ProjectConfiguration Include="Debug|Win32">
     <ProjectConfiguration Include="Debug|Win32">
       <Configuration>Debug</Configuration>
       <Configuration>Debug</Configuration>
       <Platform>Win32</Platform>
       <Platform>Win32</Platform>
@@ -42,6 +50,13 @@
     <WholeProgramOptimization>true</WholeProgramOptimization>
     <WholeProgramOptimization>true</WholeProgramOptimization>
     <CharacterSet>NotSet</CharacterSet>
     <CharacterSet>NotSet</CharacterSet>
   </PropertyGroup>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugRelease|Win32'" Label="Configuration">
+    <ConfigurationType>Application</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <PlatformToolset>v120</PlatformToolset>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>NotSet</CharacterSet>
+  </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
     <ConfigurationType>Application</ConfigurationType>
     <ConfigurationType>Application</ConfigurationType>
     <UseDebugLibraries>false</UseDebugLibraries>
     <UseDebugLibraries>false</UseDebugLibraries>
@@ -49,6 +64,13 @@
     <WholeProgramOptimization>true</WholeProgramOptimization>
     <WholeProgramOptimization>true</WholeProgramOptimization>
     <CharacterSet>NotSet</CharacterSet>
     <CharacterSet>NotSet</CharacterSet>
   </PropertyGroup>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugRelease|x64'" Label="Configuration">
+    <ConfigurationType>Application</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <PlatformToolset>v120</PlatformToolset>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>NotSet</CharacterSet>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
   </ImportGroup>
@@ -61,9 +83,15 @@
   <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
   <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
   </ImportGroup>
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='DebugRelease|Win32'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+  </ImportGroup>
   <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
   <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
   </ImportGroup>
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='DebugRelease|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
     <OutDir>..\bin\x86\$(Configuration)\</OutDir>
     <OutDir>..\bin\x86\$(Configuration)\</OutDir>
@@ -77,10 +105,20 @@
     <OutDir>..\bin\x86\$(Configuration)\</OutDir>
     <OutDir>..\bin\x86\$(Configuration)\</OutDir>
     <IntDir>.\Intermediate\$(Platform)\$(Configuration)\</IntDir>
     <IntDir>.\Intermediate\$(Platform)\$(Configuration)\</IntDir>
   </PropertyGroup>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugRelease|Win32'">
+    <OutDir>..\bin\x86\$(Configuration)\</OutDir>
+    <IntDir>.\Intermediate\$(Platform)\$(Configuration)\</IntDir>
+    <LinkIncremental>false</LinkIncremental>
+  </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
     <IntDir>.\Intermediate\$(Platform)\$(Configuration)\</IntDir>
     <IntDir>.\Intermediate\$(Platform)\$(Configuration)\</IntDir>
     <OutDir>..\bin\$(Platform)\$(Configuration)\</OutDir>
     <OutDir>..\bin\$(Platform)\$(Configuration)\</OutDir>
   </PropertyGroup>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugRelease|x64'">
+    <IntDir>.\Intermediate\$(Platform)\$(Configuration)\</IntDir>
+    <OutDir>..\bin\$(Platform)\$(Configuration)\</OutDir>
+    <LinkIncremental>false</LinkIncremental>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
     <ClCompile>
     <ClCompile>
       <WarningLevel>Level3</WarningLevel>
       <WarningLevel>Level3</WarningLevel>
@@ -125,6 +163,25 @@
       <AdditionalDependencies>BansheeCore.lib;BansheeUtility.lib;BansheeEngine.lib;%(AdditionalDependencies)</AdditionalDependencies>
       <AdditionalDependencies>BansheeCore.lib;BansheeUtility.lib;BansheeEngine.lib;%(AdditionalDependencies)</AdditionalDependencies>
     </Link>
     </Link>
   </ItemDefinitionGroup>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugRelease|Win32'">
+    <ClCompile>
+      <WarningLevel>Level3</WarningLevel>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <SDLCheck>true</SDLCheck>
+      <AdditionalIncludeDirectories>.\Include;..\BansheeCore\Include;..\BansheeUtility\Include;..\Dependencies\Include;..\BansheeEngine\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <DebugInformationFormat>OldStyle</DebugInformationFormat>
+      <MinimalRebuild>true</MinimalRebuild>
+    </ClCompile>
+    <Link>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>..\lib\x86\$(Configuration);..\Dependencies\lib\x86\Debug;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>BansheeCore.lib;BansheeUtility.lib;BansheeEngine.lib;%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
     <ClCompile>
     <ClCompile>
       <WarningLevel>Level3</WarningLevel>
       <WarningLevel>Level3</WarningLevel>
@@ -139,7 +196,26 @@
       <GenerateDebugInformation>false</GenerateDebugInformation>
       <GenerateDebugInformation>false</GenerateDebugInformation>
       <EnableCOMDATFolding>true</EnableCOMDATFolding>
       <EnableCOMDATFolding>true</EnableCOMDATFolding>
       <OptimizeReferences>true</OptimizeReferences>
       <OptimizeReferences>true</OptimizeReferences>
-      <AdditionalLibraryDirectories>..\lib\x64\$(Configuration);..\Dependencies\lib\x64\Debug;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalLibraryDirectories>..\lib\x64\$(Configuration);..\Dependencies\lib\x64\Release;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>BansheeCore.lib;BansheeUtility.lib;BansheeEngine.lib;%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugRelease|x64'">
+    <ClCompile>
+      <WarningLevel>Level3</WarningLevel>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <SDLCheck>true</SDLCheck>
+      <AdditionalIncludeDirectories>.\Include;..\BansheeCore\Include;..\BansheeUtility\Include;..\Dependencies\Include;..\BansheeEngine\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
+      <MinimalRebuild>true</MinimalRebuild>
+    </ClCompile>
+    <Link>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>..\lib\x64\$(Configuration);..\Dependencies\lib\x64\DebugRelease;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
       <AdditionalDependencies>BansheeCore.lib;BansheeUtility.lib;BansheeEngine.lib;%(AdditionalDependencies)</AdditionalDependencies>
       <AdditionalDependencies>BansheeCore.lib;BansheeUtility.lib;BansheeEngine.lib;%(AdditionalDependencies)</AdditionalDependencies>
     </Link>
     </Link>
   </ItemDefinitionGroup>
   </ItemDefinitionGroup>

+ 1 - 1
Polish.txt

@@ -2,12 +2,12 @@ Polish TODO:
  - Finalize example with resolution settings and proper GUI
  - Finalize example with resolution settings and proper GUI
   - Ensure that going fullscreen and windowed works fine
   - Ensure that going fullscreen and windowed works fine
  - Add an example model
  - Add an example model
- - Test release build
  - Test if example shuts down fine
  - Test if example shuts down fine
 
 
  - Add license text to all files
  - Add license text to all files
 
 
  - Make a separate release branch with no editor/script stuff, and without .txt files and other development data
  - Make a separate release branch with no editor/script stuff, and without .txt files and other development data
+  - Name the branch BansheeEnginePreview
   - Before I branch make a separate solution with example only projects
   - Before I branch make a separate solution with example only projects
   - Also remove all non-example code (e.g. plugin loading and similar)
   - Also remove all non-example code (e.g. plugin loading and similar)
   - This is so I can then merge that code back in that branch when ready
   - This is so I can then merge that code back in that branch when ready