port from perforce
This commit is contained in:
77
aquarium/aquarium.sln
Normal file
77
aquarium/aquarium.sln
Normal file
@@ -0,0 +1,77 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 15
|
||||
VisualStudioVersion = 15.0.26403.0
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "aquarium", "src\intro\intro.vcxproj", "{EC001821-5569-4BB5-87B3-20CB8FF9137B}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF} = {6D00EB12-7129-482A-8011-F187F20345DF}
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931} = {930621BA-75BE-49FE-80DE-E75E7DC06931}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "tool", "src\tool\tool.csproj", "{6D00EB12-7129-482A-8011-F187F20345DF}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931} = {930621BA-75BE-49FE-80DE-E75E7DC06931}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "shc", "src\shc\shc.csproj", "{930621BA-75BE-49FE-80DE-E75E7DC06931}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(Performance) = preSolution
|
||||
HasPerformanceSessions = true
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Authoring|Mixed Platforms = Authoring|Mixed Platforms
|
||||
Compress|Mixed Platforms = Compress|Mixed Platforms
|
||||
Release|Mixed Platforms = Release|Mixed Platforms
|
||||
ShaderDebug|Mixed Platforms = ShaderDebug|Mixed Platforms
|
||||
Video|Mixed Platforms = Video|Mixed Platforms
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.Authoring|Mixed Platforms.ActiveCfg = Authoring|Win32
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.Authoring|Mixed Platforms.Build.0 = Authoring|Win32
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.Compress|Mixed Platforms.ActiveCfg = Compress|Win32
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.Compress|Mixed Platforms.Build.0 = Compress|Win32
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.ShaderDebug|Mixed Platforms.ActiveCfg = ShaderDebug|Win32
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.ShaderDebug|Mixed Platforms.Build.0 = ShaderDebug|Win32
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.Video|Mixed Platforms.ActiveCfg = Video|Win32
|
||||
{EC001821-5569-4BB5-87B3-20CB8FF9137B}.Video|Mixed Platforms.Build.0 = Video|Win32
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.Authoring|Mixed Platforms.ActiveCfg = Authoring|Any CPU
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.Authoring|Mixed Platforms.Build.0 = Authoring|Any CPU
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.Compress|Mixed Platforms.ActiveCfg = Void|Any CPU
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.Compress|Mixed Platforms.Build.0 = Void|Any CPU
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.Release|Mixed Platforms.ActiveCfg = Void|Any CPU
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.Release|Mixed Platforms.Build.0 = Void|Any CPU
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.ShaderDebug|Mixed Platforms.ActiveCfg = Void|Any CPU
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.ShaderDebug|Mixed Platforms.Build.0 = Void|Any CPU
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.Video|Mixed Platforms.ActiveCfg = Void|Any CPU
|
||||
{6D00EB12-7129-482A-8011-F187F20345DF}.Video|Mixed Platforms.Build.0 = Void|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.Authoring|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.Authoring|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.Compress|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.Compress|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.Release|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.Release|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.ShaderDebug|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.ShaderDebug|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.Video|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||
{930621BA-75BE-49FE-80DE-E75E7DC06931}.Video|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(Performance) = preSolution
|
||||
HasPerformanceSessions = true
|
||||
EndGlobalSection
|
||||
GlobalSection(Performance) = preSolution
|
||||
HasPerformanceSessions = true
|
||||
EndGlobalSection
|
||||
GlobalSection(Performance) = preSolution
|
||||
HasPerformanceSessions = true
|
||||
EndGlobalSection
|
||||
GlobalSection(Performance) = preSolution
|
||||
HasPerformanceSessions = true
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
BIN
aquarium/intro.docx
Normal file
BIN
aquarium/intro.docx
Normal file
Binary file not shown.
BIN
aquarium/packages/AvalonEdit.5.0.2/AvalonEdit.5.0.2.nupkg
vendored
Normal file
BIN
aquarium/packages/AvalonEdit.5.0.2/AvalonEdit.5.0.2.nupkg
vendored
Normal file
Binary file not shown.
33
aquarium/packages/AvalonEdit.5.0.2/AvalonEdit.5.0.2.nuspec
vendored
Normal file
33
aquarium/packages/AvalonEdit.5.0.2/AvalonEdit.5.0.2.nuspec
vendored
Normal file
@@ -0,0 +1,33 @@
|
||||
<?xml version="1.0"?>
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>AvalonEdit</id>
|
||||
<version>5.0.2</version>
|
||||
<authors>Daniel Grunwald</authors>
|
||||
<owners>Daniel Grunwald</owners>
|
||||
<licenseUrl>http://opensource.org/licenses/MIT</licenseUrl>
|
||||
<projectUrl>http://www.avalonedit.net/</projectUrl>
|
||||
<iconUrl>http://community.sharpdevelop.net/blogs/mattward/SharpDevelop.png</iconUrl>
|
||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||
<description>AvalonEdit is the WPF-based text editor used in SharpDevelop. There are two builds of AvalonEdit included in this package. One that targets .NET 4.0 and one that targets .NET 3.5.</description>
|
||||
<summary>AvalonEdit is the WPF-based text editor used in SharpDevelop</summary>
|
||||
<releaseNotes>* License changed from LGPL to MIT
|
||||
* New Feature: Hide mouse cursor while typing (enabled by default)
|
||||
* New Feature: Highlight current line (disabled by default)
|
||||
* New Feature: Overstrike mode (disabled by default)
|
||||
* New Feature: 'underline' attribute in syntax highlighting definitions
|
||||
* AvalonEdit now raises the WPF DataObject attached events on clipboard and drag'n'drop operations.
|
||||
* Encoding detection now distinguishes between UTF-8 with BOM and UTF-8 without BOM. This prevents AvalonEdit from adding the BOM to existing UTF-8 files.
|
||||
* Improved handling of grapheme clusters. A base character followed by a combining mark is now treated as a single character by the caret movement logic.
|
||||
* Added RichText, RichTextModel and RichTextColorizer.
|
||||
* Renamed the VB highlighting mode from "VBNET" to "VB"
|
||||
* Changed IHighlighter API in order to support SharpDevelop's semantic C# highlighter
|
||||
* The regex-based highlighting engine was moved into its own class (HighlightingEngine) to be separated from the state-tracking logic in DocumentHighlighter.
|
||||
* Add FileName property to TextDocument class.
|
||||
* DocumentChangeEventArgs.RemovedText/InsertedText are now of type ITextSource instead of string.
|
||||
* The error-tolerant XML parser included with AvalonEdit was removed. An improved version of this parser is part of the NRefactory 5 project.
|
||||
* Removed some obsolete APIs.</releaseNotes>
|
||||
<language>en-US</language>
|
||||
<tags>WPF Text Editor SharpDevelop AvalonEdit</tags>
|
||||
</metadata>
|
||||
</package>
|
||||
BIN
aquarium/packages/AvalonEdit.5.0.2/lib/Net35/ICSharpCode.AvalonEdit.dll
vendored
Normal file
BIN
aquarium/packages/AvalonEdit.5.0.2/lib/Net35/ICSharpCode.AvalonEdit.dll
vendored
Normal file
Binary file not shown.
9939
aquarium/packages/AvalonEdit.5.0.2/lib/Net35/ICSharpCode.AvalonEdit.xml
vendored
Normal file
9939
aquarium/packages/AvalonEdit.5.0.2/lib/Net35/ICSharpCode.AvalonEdit.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/AvalonEdit.5.0.2/lib/Net40/ICSharpCode.AvalonEdit.dll
vendored
Normal file
BIN
aquarium/packages/AvalonEdit.5.0.2/lib/Net40/ICSharpCode.AvalonEdit.dll
vendored
Normal file
Binary file not shown.
9939
aquarium/packages/AvalonEdit.5.0.2/lib/Net40/ICSharpCode.AvalonEdit.xml
vendored
Normal file
9939
aquarium/packages/AvalonEdit.5.0.2/lib/Net40/ICSharpCode.AvalonEdit.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.4.0.1/SharpDX.4.0.1.nupkg
vendored
Normal file
BIN
aquarium/packages/SharpDX.4.0.1/SharpDX.4.0.1.nupkg
vendored
Normal file
Binary file not shown.
BIN
aquarium/packages/SharpDX.4.0.1/lib/net40/SharpDX.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.4.0.1/lib/net40/SharpDX.dll
vendored
Normal file
Binary file not shown.
38946
aquarium/packages/SharpDX.4.0.1/lib/net40/SharpDX.xml
vendored
Normal file
38946
aquarium/packages/SharpDX.4.0.1/lib/net40/SharpDX.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.4.0.1/lib/net45/SharpDX.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.4.0.1/lib/net45/SharpDX.dll
vendored
Normal file
Binary file not shown.
38946
aquarium/packages/SharpDX.4.0.1/lib/net45/SharpDX.xml
vendored
Normal file
38946
aquarium/packages/SharpDX.4.0.1/lib/net45/SharpDX.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.4.0.1/lib/netcoreapp1.0/SharpDX.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.4.0.1/lib/netcoreapp1.0/SharpDX.dll
vendored
Normal file
Binary file not shown.
38946
aquarium/packages/SharpDX.4.0.1/lib/netcoreapp1.0/SharpDX.xml
vendored
Normal file
38946
aquarium/packages/SharpDX.4.0.1/lib/netcoreapp1.0/SharpDX.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.4.0.1/lib/netstandard1.1/SharpDX.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.4.0.1/lib/netstandard1.1/SharpDX.dll
vendored
Normal file
Binary file not shown.
38957
aquarium/packages/SharpDX.4.0.1/lib/netstandard1.1/SharpDX.xml
vendored
Normal file
38957
aquarium/packages/SharpDX.4.0.1/lib/netstandard1.1/SharpDX.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.4.0.1/lib/uap10.0/SharpDX.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.4.0.1/lib/uap10.0/SharpDX.dll
vendored
Normal file
Binary file not shown.
BIN
aquarium/packages/SharpDX.4.0.1/lib/uap10.0/SharpDX.pri
vendored
Normal file
BIN
aquarium/packages/SharpDX.4.0.1/lib/uap10.0/SharpDX.pri
vendored
Normal file
Binary file not shown.
34497
aquarium/packages/SharpDX.4.0.1/lib/uap10.0/SharpDX.xml
vendored
Normal file
34497
aquarium/packages/SharpDX.4.0.1/lib/uap10.0/SharpDX.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/SharpDX.Mathematics.4.0.1.nupkg
vendored
Normal file
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/SharpDX.Mathematics.4.0.1.nupkg
vendored
Normal file
Binary file not shown.
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/net40/SharpDX.Mathematics.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/net40/SharpDX.Mathematics.dll
vendored
Normal file
Binary file not shown.
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/net40/SharpDX.Mathematics.xml
vendored
Normal file
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/net40/SharpDX.Mathematics.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/net45/SharpDX.Mathematics.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/net45/SharpDX.Mathematics.dll
vendored
Normal file
Binary file not shown.
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/net45/SharpDX.Mathematics.xml
vendored
Normal file
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/net45/SharpDX.Mathematics.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/netcoreapp1.0/SharpDX.Mathematics.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/netcoreapp1.0/SharpDX.Mathematics.dll
vendored
Normal file
Binary file not shown.
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/netcoreapp1.0/SharpDX.Mathematics.xml
vendored
Normal file
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/netcoreapp1.0/SharpDX.Mathematics.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/netstandard1.1/SharpDX.Mathematics.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/netstandard1.1/SharpDX.Mathematics.dll
vendored
Normal file
Binary file not shown.
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/netstandard1.1/SharpDX.Mathematics.xml
vendored
Normal file
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/netstandard1.1/SharpDX.Mathematics.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/uap10.0/SharpDX.Mathematics.dll
vendored
Normal file
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/uap10.0/SharpDX.Mathematics.dll
vendored
Normal file
Binary file not shown.
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/uap10.0/SharpDX.Mathematics.pri
vendored
Normal file
BIN
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/uap10.0/SharpDX.Mathematics.pri
vendored
Normal file
Binary file not shown.
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/uap10.0/SharpDX.Mathematics.xml
vendored
Normal file
16396
aquarium/packages/SharpDX.Mathematics.4.0.1/lib/uap10.0/SharpDX.Mathematics.xml
vendored
Normal file
File diff suppressed because it is too large
Load Diff
4
aquarium/packages/repositories.config
Normal file
4
aquarium/packages/repositories.config
Normal file
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<repositories>
|
||||
<repository path="..\src\tool\packages.config" />
|
||||
</repositories>
|
||||
13
aquarium/src/intro/crinkler.html
Normal file
13
aquarium/src/intro/crinkler.html
Normal file
File diff suppressed because one or more lines are too long
663
aquarium/src/intro/framework/authoring.h
Normal file
663
aquarium/src/intro/framework/authoring.h
Normal file
@@ -0,0 +1,663 @@
|
||||
#pragma once
|
||||
|
||||
#include <Shlwapi.h>
|
||||
#include <immintrin.h>
|
||||
|
||||
static HANDLE shaderCompileEvent;
|
||||
static bool shadersOK = true;
|
||||
|
||||
struct SharedMemoryToolType
|
||||
{
|
||||
int WindowWidth;
|
||||
int WindowHeight;
|
||||
int MaxSamples;
|
||||
int SampleSize;
|
||||
int SamplesPerTick;
|
||||
int TicksPerScene;
|
||||
float IntroPosition;
|
||||
int AudioRenderPosition;
|
||||
int SeekToRow;
|
||||
HWND introHandle;
|
||||
HWND analysisHandle;
|
||||
int KeepAlive;
|
||||
int DisplayTextureIndex;
|
||||
int AudioIsPlaying;
|
||||
int CanCaptureFrame;
|
||||
int CaptureOneFrame;
|
||||
};
|
||||
|
||||
static D3D11_TEXTURE2D_DESC histogramTextureDesc =
|
||||
{
|
||||
256,
|
||||
256,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
{ 1, 0 },
|
||||
D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_UNORDERED_ACCESS,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
static D3D11_TEXTURE2D_DESC histogramStagingTextureDesc =
|
||||
{
|
||||
256,
|
||||
256,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
{ 1, 0 },
|
||||
D3D11_USAGE_STAGING,
|
||||
0,
|
||||
D3D11_CPU_ACCESS_READ,
|
||||
0
|
||||
};
|
||||
|
||||
static D3D11_TEXTURE1D_DESC histogramBucketTextureDesc =
|
||||
{
|
||||
257,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R32_UINT,
|
||||
D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_UNORDERED_ACCESS,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
static D3D11_TEXTURE2D_DESC paradeVectorScopeBucketTextureDesc =
|
||||
{
|
||||
257,
|
||||
256,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R32_UINT,
|
||||
{ 1, 0 },
|
||||
D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_UNORDERED_ACCESS,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
static D3D11_TEXTURE2D_DESC paradeTextureDesc =
|
||||
{
|
||||
4 * 256,
|
||||
256,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
{ 1, 0 },
|
||||
D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_UNORDERED_ACCESS,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
static D3D11_TEXTURE2D_DESC paradeStagingTextureDesc =
|
||||
{
|
||||
4 * 256,
|
||||
256,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
{ 1, 0 },
|
||||
D3D11_USAGE_STAGING,
|
||||
0,
|
||||
D3D11_CPU_ACCESS_READ,
|
||||
0
|
||||
};
|
||||
|
||||
static D3D11_TEXTURE2D_DESC vectorScopeTextureDesc =
|
||||
{
|
||||
256,
|
||||
256,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
{ 1, 0 },
|
||||
D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_UNORDERED_ACCESS,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
static D3D11_TEXTURE2D_DESC vectorScopeStagingTextureDesc =
|
||||
{
|
||||
256,
|
||||
256,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
{ 1, 0 },
|
||||
D3D11_USAGE_STAGING,
|
||||
0,
|
||||
D3D11_CPU_ACCESS_READ,
|
||||
0
|
||||
};
|
||||
|
||||
static D3D11_UNORDERED_ACCESS_VIEW_DESC histogramUAVdesc =
|
||||
{
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
D3D11_UAV_DIMENSION_TEXTURE2D,
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
static D3D11_UNORDERED_ACCESS_VIEW_DESC histogramBucketUAVdesc =
|
||||
{
|
||||
DXGI_FORMAT_R32_UINT,
|
||||
D3D11_UAV_DIMENSION_TEXTURE1D,
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
static D3D11_UNORDERED_ACCESS_VIEW_DESC paradeUAVdesc =
|
||||
{
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
D3D11_UAV_DIMENSION_TEXTURE2D,
|
||||
{ 0, 1 }
|
||||
};
|
||||
|
||||
static D3D11_UNORDERED_ACCESS_VIEW_DESC paradeVectorScopeBucketUAVdesc =
|
||||
{
|
||||
DXGI_FORMAT_R32_UINT,
|
||||
D3D11_UAV_DIMENSION_TEXTURE2D,
|
||||
{ 0, 1 }
|
||||
};
|
||||
|
||||
static D3D11_UNORDERED_ACCESS_VIEW_DESC vectorScopeUAVdesc =
|
||||
{
|
||||
DXGI_FORMAT_R8G8B8A8_UINT,
|
||||
D3D11_UAV_DIMENSION_TEXTURE2D,
|
||||
{ 0, 1 }
|
||||
};
|
||||
|
||||
static D3D11_SHADER_RESOURCE_VIEW_DESC analysisSRVdesc =
|
||||
{
|
||||
DXGI_FORMAT_B8G8R8A8_UNORM,
|
||||
D3D11_SRV_DIMENSION_TEXTURE2DMS,
|
||||
{ 0, 1 }
|
||||
};
|
||||
|
||||
static D3D11_RENDER_TARGET_VIEW_DESC resolveRTVdesc =
|
||||
{
|
||||
DXGI_FORMAT_B8G8R8A8_UNORM,
|
||||
D3D11_RTV_DIMENSION_TEXTURE2DMS,
|
||||
{ 0, 1 }
|
||||
};
|
||||
|
||||
static SharedMemoryToolType* SharedMemoryTool;
|
||||
static char* SharedImage;
|
||||
static HANDLE AudioFileMapping;
|
||||
static HANDLE ImageFileMapping;
|
||||
static HANDLE HistogramFileMapping;
|
||||
static HANDLE ParadeFileMapping;
|
||||
static HANDLE VectorscopeFileMapping;
|
||||
static HANDLE SharedMemoryFileMapping;
|
||||
static HANDLE SyncDataFileMapping;
|
||||
static HANDLE SyncOverrideDataFileMapping;
|
||||
static HANDLE DisplayTextureFileMapping;
|
||||
static HANDLE TextureNamesFileMapping;
|
||||
static bool playMusic;
|
||||
static long musicStartOffset;
|
||||
static D3D11_TEXTURE2D_DESC analysisDesc;
|
||||
static D3D11_TEXTURE2D_DESC displayDesc;
|
||||
static ID3D11Texture2D* resolvedTexture;
|
||||
static ID3D11Texture2D* stagingTexture;
|
||||
static ID3D11Texture2D* histogramTexture;
|
||||
static ID3D11Texture1D* histogramRedBucketTexture;
|
||||
static ID3D11Texture1D* histogramGreenBucketTexture;
|
||||
static ID3D11Texture1D* histogramBlueBucketTexture;
|
||||
static ID3D11Texture2D* histogramStagingTexture;
|
||||
static ID3D11Texture2D* paradeRedBucketTexture;
|
||||
static ID3D11Texture2D* paradeGreenBucketTexture;
|
||||
static ID3D11Texture2D* paradeBlueBucketTexture;
|
||||
static ID3D11Texture2D* paradeAlphaBucketTexture;
|
||||
static ID3D11Texture2D* paradeTexture;
|
||||
static ID3D11Texture2D* paradeStagingTexture;
|
||||
static ID3D11Texture2D* vectorScopeBucketTexture;
|
||||
static ID3D11Texture2D* vectorScopeTexture;
|
||||
static ID3D11Texture2D* vectorScopeStagingTexture;
|
||||
static ID3D11Texture2D* displayRGBTexture;
|
||||
static ID3D11Texture2D* displayATexture;
|
||||
static ID3D11Texture2D* displayStagingTexture;
|
||||
static ID3D11ComputeShader* csHistogramGather;
|
||||
static ID3D11ComputeShader* csHistogramMaximum;
|
||||
static ID3D11ComputeShader* csHistogramSpread;
|
||||
static ID3D11ComputeShader* csParadeVectorscopeGather;
|
||||
static ID3D11ComputeShader* csParadeVectorscopeMaximum;
|
||||
static ID3D11ComputeShader* csParadeVectorscopeSpread;
|
||||
static ID3D11PixelShader* psResolve;
|
||||
static ID3D11VertexShader* vsResolve;
|
||||
static ID3D11RenderTargetView* resolvedRTV;
|
||||
static ID3D11ComputeShader* csTextureViewer;
|
||||
static ID3D11UnorderedAccessView* histogramUAV;
|
||||
static ID3D11UnorderedAccessView* histogramRedBucketUAV;
|
||||
static ID3D11UnorderedAccessView* histogramGreenBucketUAV;
|
||||
static ID3D11UnorderedAccessView* histogramBlueBucketUAV;
|
||||
static ID3D11UnorderedAccessView* paradeUAV;
|
||||
static ID3D11UnorderedAccessView* paradeRedBucketUAV;
|
||||
static ID3D11UnorderedAccessView* paradeGreenBucketUAV;
|
||||
static ID3D11UnorderedAccessView* paradeBlueBucketUAV;
|
||||
static ID3D11UnorderedAccessView* paradeAlphaBucketUAV;
|
||||
static ID3D11UnorderedAccessView* vectorScopeUAV;
|
||||
static ID3D11UnorderedAccessView* displayRGBUAV;
|
||||
static ID3D11UnorderedAccessView* displayAUAV;
|
||||
static ID3D11UnorderedAccessView* vectorScopeBucketUAV;
|
||||
static ID3D11ShaderResourceView* analysisSRV;
|
||||
static D3D11_MAPPED_SUBRESOURCE mappedResource;
|
||||
static float* histogram;
|
||||
static float* parade;
|
||||
static float* vectorscope;
|
||||
static char* syncDataAudio;
|
||||
static char* syncOverrideData;
|
||||
static char* displayTextureData;
|
||||
static char* textureNamesData;
|
||||
static HANDLE hShaderErrorPipe;
|
||||
static bool oldAudioIsPlaying;
|
||||
|
||||
extern "C" int _4klang_current_tick;
|
||||
|
||||
float AuthoringGetIntroPosition()
|
||||
{
|
||||
float time = SoundGetIntroPosition();
|
||||
return time + musicStartOffset / (float)(SAMPLES_PER_TICK * SOUND_TICKS_PER_SCENE);
|
||||
}
|
||||
|
||||
bool ReadFile(char* path, char** content, size_t* length)
|
||||
{
|
||||
FILE* shaderFile;
|
||||
auto error = fopen_s(&shaderFile, path, "rb");
|
||||
if (shaderFile == nullptr)
|
||||
return false;
|
||||
|
||||
fseek(shaderFile, 0, SEEK_END);
|
||||
*length = ftell(shaderFile);
|
||||
*content = new char[*length];
|
||||
fseek(shaderFile, 0, SEEK_SET);
|
||||
fread_s(*content, *length, sizeof(char), *length, shaderFile);
|
||||
fclose(shaderFile);
|
||||
return true;
|
||||
}
|
||||
|
||||
void AuthoringInit()
|
||||
{
|
||||
Log("AuthoringInit");
|
||||
SharedMemoryFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, sizeof(SharedMemoryToolType), "IntroAuthor");
|
||||
AudioFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, sizeof(float) * MAX_SAMPLES * 2, "IntroAudio");
|
||||
ImageFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, 4 * SCREENWIDTH * SCREENHEIGHT, "IntroImage");
|
||||
HistogramFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, 4 * 256 * 256, "IntroHistogram");
|
||||
ParadeFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, 4 * 4 * 256 * 256, "IntroParade");
|
||||
VectorscopeFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, 4 * 256 * 256, "IntroVectorscope");
|
||||
DisplayTextureFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, 9 + 8 * 4096 * 4096, "IntroDisplayTexture");
|
||||
TextureNamesFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, 256 * 256, "IntroTextureNames");
|
||||
SyncDataFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, 1048576, "TimelineNode.Audio");
|
||||
SyncOverrideDataFileMapping = CreateFileMapping(INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, 0, 1048576, "TimelineNode.Override.Audio");
|
||||
|
||||
SharedMemoryTool = (SharedMemoryToolType*)MapViewOfFile(SharedMemoryFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, sizeof(SharedMemoryToolType));
|
||||
soundBuffer = (float*)MapViewOfFile(AudioFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, sizeof(float)* MAX_SAMPLES * 2);
|
||||
SharedImage = (char*)MapViewOfFile(ImageFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, 4 * SCREENWIDTH * SCREENHEIGHT);
|
||||
histogram = (float*)MapViewOfFile(HistogramFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, 4 * 256 * 256);
|
||||
parade = (float*)MapViewOfFile(ParadeFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, 4 * 4 * 256 * 256);
|
||||
vectorscope = (float*)MapViewOfFile(VectorscopeFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, 4 * 256 * 256);
|
||||
syncDataAudio = (char*)MapViewOfFile(SyncDataFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, 1048576);
|
||||
syncOverrideData = (char*)MapViewOfFile(SyncOverrideDataFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, 1048576);
|
||||
displayTextureData = (char*)MapViewOfFile(DisplayTextureFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, 9 + 8 * 4096 * 4096);
|
||||
textureNamesData = (char*)MapViewOfFile(TextureNamesFileMapping, FILE_MAP_ALL_ACCESS, 0, 0, 256 * 256);
|
||||
|
||||
auto pTextureNames = textureNamesData;
|
||||
*pTextureNames++ = (char)textureMap.size();
|
||||
for (auto texture : textureMap)
|
||||
{
|
||||
auto iSize = (char)strlen(texture.first);
|
||||
*pTextureNames++ = iSize;
|
||||
memcpy(pTextureNames, texture.first, iSize);
|
||||
pTextureNames += iSize;
|
||||
}
|
||||
displayTextureData[0] = (char)-1;
|
||||
|
||||
WaveHDR.lpData = (LPSTR)soundBuffer;
|
||||
SharedMemoryTool->WindowWidth = SCREENWIDTH;
|
||||
SharedMemoryTool->WindowHeight = SCREENHEIGHT;
|
||||
SharedMemoryTool->MaxSamples = MAX_SAMPLES;
|
||||
SharedMemoryTool->SampleSize = sizeof(float);
|
||||
SharedMemoryTool->SamplesPerTick = SAMPLES_PER_TICK;
|
||||
SharedMemoryTool->TicksPerScene = SOUND_TICKS_PER_SCENE;
|
||||
SharedMemoryTool->SeekToRow = -1;
|
||||
SharedMemoryTool->KeepAlive = true;
|
||||
SharedMemoryTool->DisplayTextureIndex = -1;
|
||||
SharedMemoryTool->AudioIsPlaying = true;
|
||||
|
||||
backBufferTexture->GetDesc(&analysisDesc);
|
||||
analysisDesc.Usage = D3D11_USAGE_DEFAULT;
|
||||
analysisDesc.Format = DXGI_FORMAT_B8G8R8A8_TYPELESS;
|
||||
analysisDesc.BindFlags = D3D11_BIND_SHADER_RESOURCE | D3D11_BIND_RENDER_TARGET;
|
||||
analysisDesc.SampleDesc.Count = 1;
|
||||
device->CreateTexture2D(&analysisDesc, NULL, &resolvedTexture);
|
||||
|
||||
analysisDesc.Usage = D3D11_USAGE_STAGING;
|
||||
analysisDesc.BindFlags = 0;
|
||||
analysisDesc.CPUAccessFlags |= D3D11_CPU_ACCESS_READ;
|
||||
device->CreateTexture2D(&analysisDesc, NULL, &stagingTexture);
|
||||
device->CreateShaderResourceView(resolvedTexture, &analysisSRVdesc, &analysisSRV);
|
||||
device->CreateRenderTargetView(resolvedTexture, &resolveRTVdesc, &resolvedRTV);
|
||||
|
||||
device->CreateTexture2D(&histogramTextureDesc, NULL, &histogramTexture);
|
||||
device->CreateTexture1D(&histogramBucketTextureDesc, NULL, &histogramRedBucketTexture);
|
||||
device->CreateTexture1D(&histogramBucketTextureDesc, NULL, &histogramGreenBucketTexture);
|
||||
device->CreateTexture1D(&histogramBucketTextureDesc, NULL, &histogramBlueBucketTexture);
|
||||
device->CreateUnorderedAccessView(histogramTexture, &histogramUAVdesc, &histogramUAV);
|
||||
device->CreateUnorderedAccessView(histogramRedBucketTexture, &histogramBucketUAVdesc, &histogramRedBucketUAV);
|
||||
device->CreateUnorderedAccessView(histogramGreenBucketTexture, &histogramBucketUAVdesc, &histogramGreenBucketUAV);
|
||||
device->CreateUnorderedAccessView(histogramBlueBucketTexture, &histogramBucketUAVdesc, &histogramBlueBucketUAV);
|
||||
device->CreateTexture2D(&histogramStagingTextureDesc, NULL, &histogramStagingTexture);
|
||||
|
||||
device->CreateTexture2D(¶deVectorScopeBucketTextureDesc, NULL, ¶deRedBucketTexture);
|
||||
device->CreateTexture2D(¶deVectorScopeBucketTextureDesc, NULL, ¶deGreenBucketTexture);
|
||||
device->CreateTexture2D(¶deVectorScopeBucketTextureDesc, NULL, ¶deBlueBucketTexture);
|
||||
device->CreateTexture2D(¶deVectorScopeBucketTextureDesc, NULL, ¶deAlphaBucketTexture);
|
||||
device->CreateTexture2D(¶deVectorScopeBucketTextureDesc, NULL, &vectorScopeBucketTexture);
|
||||
|
||||
device->CreateTexture2D(¶deTextureDesc, NULL, ¶deTexture);
|
||||
device->CreateTexture2D(¶deStagingTextureDesc, NULL, ¶deStagingTexture);
|
||||
device->CreateTexture2D(&vectorScopeTextureDesc, NULL, &vectorScopeTexture);
|
||||
device->CreateTexture2D(&vectorScopeStagingTextureDesc, NULL, &vectorScopeStagingTexture);
|
||||
|
||||
device->CreateUnorderedAccessView(paradeRedBucketTexture, ¶deVectorScopeBucketUAVdesc, ¶deRedBucketUAV);
|
||||
device->CreateUnorderedAccessView(paradeGreenBucketTexture, ¶deVectorScopeBucketUAVdesc, ¶deGreenBucketUAV);
|
||||
device->CreateUnorderedAccessView(paradeBlueBucketTexture, ¶deVectorScopeBucketUAVdesc, ¶deBlueBucketUAV);
|
||||
device->CreateUnorderedAccessView(paradeAlphaBucketTexture, ¶deVectorScopeBucketUAVdesc, ¶deAlphaBucketUAV);
|
||||
device->CreateUnorderedAccessView(vectorScopeBucketTexture, ¶deVectorScopeBucketUAVdesc, &vectorScopeBucketUAV);
|
||||
device->CreateUnorderedAccessView(vectorScopeTexture, &vectorScopeUAVdesc, &vectorScopeUAV);
|
||||
device->CreateUnorderedAccessView(paradeTexture, ¶deUAVdesc, ¶deUAV);
|
||||
|
||||
static char shaderPath[MAX_PATH];
|
||||
static char exePath[MAX_PATH];
|
||||
static char* shaderCode;
|
||||
static size_t shaderLength;
|
||||
|
||||
GetModuleFileName(NULL, exePath, MAX_PATH);
|
||||
PathRemoveFileSpec(exePath);
|
||||
|
||||
PathCombine(shaderPath, exePath, "resolve.cso");
|
||||
ReadFile(shaderPath, &shaderCode, &shaderLength);
|
||||
device->CreatePixelShader(shaderCode, shaderLength, NULL, &psResolve);
|
||||
|
||||
PathCombine(shaderPath, exePath, "fullscreen.cso");
|
||||
ReadFile(shaderPath, &shaderCode, &shaderLength);
|
||||
device->CreateVertexShader(shaderCode, shaderLength, NULL, &vsResolve);
|
||||
|
||||
PathCombine(shaderPath, exePath, "histogramGather.cso");
|
||||
ReadFile(shaderPath, &shaderCode, &shaderLength);
|
||||
device->CreateComputeShader(shaderCode, shaderLength, NULL, &csHistogramGather);
|
||||
|
||||
PathCombine(shaderPath, exePath, "histogramMaximum.cso");
|
||||
ReadFile(shaderPath, &shaderCode, &shaderLength);
|
||||
device->CreateComputeShader(shaderCode, shaderLength, NULL, &csHistogramMaximum);
|
||||
|
||||
PathCombine(shaderPath, exePath, "histogramSpread.cso");
|
||||
ReadFile(shaderPath, &shaderCode, &shaderLength);
|
||||
device->CreateComputeShader(shaderCode, shaderLength, NULL, &csHistogramSpread);
|
||||
|
||||
PathCombine(shaderPath, exePath, "paradeVectorscopeGather.cso");
|
||||
ReadFile(shaderPath, &shaderCode, &shaderLength);
|
||||
device->CreateComputeShader(shaderCode, shaderLength, NULL, &csParadeVectorscopeGather);
|
||||
|
||||
PathCombine(shaderPath, exePath, "paradeVectorscopeMaximum.cso");
|
||||
ReadFile(shaderPath, &shaderCode, &shaderLength);
|
||||
device->CreateComputeShader(shaderCode, shaderLength, NULL, &csParadeVectorscopeMaximum);
|
||||
|
||||
PathCombine(shaderPath, exePath, "paradeVectorscopeSpread.cso");
|
||||
ReadFile(shaderPath, &shaderCode, &shaderLength);
|
||||
device->CreateComputeShader(shaderCode, shaderLength, NULL, &csParadeVectorscopeSpread);
|
||||
|
||||
PathCombine(shaderPath, exePath, "textureViewer.cso");
|
||||
ReadFile(shaderPath, &shaderCode, &shaderLength);
|
||||
device->CreateComputeShader(shaderCode, shaderLength, NULL, &csTextureViewer);
|
||||
|
||||
while (1)
|
||||
{
|
||||
auto pipeName = "\\\\.\\pipe\\8kode.error";
|
||||
hShaderErrorPipe = CreateFileA(
|
||||
pipeName, // pipe name
|
||||
GENERIC_WRITE |
|
||||
GENERIC_WRITE, // read/write access
|
||||
0, // no sharing
|
||||
NULL, // default security attributes
|
||||
OPEN_EXISTING, // opens existing pipe
|
||||
0, // default attributes
|
||||
NULL); // no template file
|
||||
|
||||
// Break if the pipe handle is valid.
|
||||
if (hShaderErrorPipe != INVALID_HANDLE_VALUE)
|
||||
break;
|
||||
|
||||
// All pipe instances are busy, so wait for 2 seconds.
|
||||
if (WaitNamedPipe(pipeName, 2000000))
|
||||
{
|
||||
printf("Could not open pipe: 2 second wait timed out.");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void SoundSeekToRow(void *d, int row)
|
||||
{
|
||||
if (row < 0)
|
||||
row = 0;
|
||||
|
||||
musicStartOffset = row * (long)(SAMPLES_PER_TICK);
|
||||
|
||||
WaveHDR.lpData = (LPSTR)(float*)(soundBuffer + musicStartOffset * 2);
|
||||
WaveHDR.dwBufferLength = (MAX_SAMPLES - musicStartOffset) * sizeof(float) * 2;
|
||||
|
||||
//send buffer to waveOut
|
||||
waveOutReset(hWaveOut);
|
||||
waveOutPrepareHeader(hWaveOut, &WaveHDR, sizeof(WaveHDR));
|
||||
waveOutWrite(hWaveOut, &WaveHDR, sizeof(WaveHDR));
|
||||
|
||||
//put on pause
|
||||
if (!SharedMemoryTool->AudioIsPlaying)
|
||||
waveOutPause(hWaveOut);
|
||||
}
|
||||
|
||||
void FrameworkShadersCompile();
|
||||
|
||||
void AuthoringUpdate()
|
||||
{
|
||||
SharedMemoryTool->IntroPosition = AuthoringGetIntroPosition();
|
||||
SharedMemoryTool->AudioRenderPosition = _4klang_current_tick * SAMPLES_PER_TICK;
|
||||
|
||||
if (oldAudioIsPlaying != (SharedMemoryTool->AudioIsPlaying != 0))
|
||||
{
|
||||
// Change audio play state
|
||||
if (SharedMemoryTool->AudioIsPlaying != 0)
|
||||
waveOutRestart(hWaveOut);
|
||||
else
|
||||
waveOutPause(hWaveOut);
|
||||
}
|
||||
oldAudioIsPlaying = (SharedMemoryTool->AudioIsPlaying != 0);
|
||||
|
||||
static ID3D11Buffer* empty[16];
|
||||
|
||||
context->CSSetConstantBuffers(0, 8, empty);
|
||||
context->VSSetConstantBuffers(0, 8, empty);
|
||||
context->GSSetConstantBuffers(0, 8, empty);
|
||||
context->HSSetConstantBuffers(0, 8, empty);
|
||||
context->DSSetConstantBuffers(0, 8, empty);
|
||||
context->PSSetConstantBuffers(0, 8, empty);
|
||||
|
||||
context->RSSetViewports(1, &swapChainViewport);
|
||||
context->OMSetRenderTargets(1, &resolvedRTV, nullptr);
|
||||
context->PSSetShaderResources(0, 1, &backBufferSRV);
|
||||
context->PSSetShader(psResolve, nullptr, 0);
|
||||
context->VSSetShader(vsResolve, nullptr, 0);
|
||||
context->IASetPrimitiveTopology(D3D11_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP);
|
||||
context->Draw(4, 0);
|
||||
context->PSSetShaderResources(0, 1, (ID3D11ShaderResourceView* const*)empty);
|
||||
context->OMSetRenderTargets(1, (ID3D11RenderTargetView* const*)empty, nullptr);
|
||||
|
||||
context->CopyResource(stagingTexture, resolvedTexture);
|
||||
context->Map(stagingTexture, 0, D3D11_MAP_READ, 0, &mappedResource);
|
||||
auto srcPtr = (char*)mappedResource.pData;
|
||||
auto dstPtr = SharedImage;
|
||||
auto endImgPtr = srcPtr + SCREENWIDTH * SCREENHEIGHT * 4;
|
||||
memcpy(SharedImage, mappedResource.pData, SCREENWIDTH * SCREENHEIGHT * 4);
|
||||
context->Unmap(stagingTexture, 0);
|
||||
|
||||
static ID3D11UnorderedAccessView* histogramUAVs[] =
|
||||
{
|
||||
0,
|
||||
histogramRedBucketUAV,
|
||||
histogramGreenBucketUAV,
|
||||
histogramBlueBucketUAV,
|
||||
histogramUAV,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
static ID3D11UnorderedAccessView* paradeVectorscopeUAVs[] =
|
||||
{
|
||||
0,
|
||||
paradeRedBucketUAV,
|
||||
paradeGreenBucketUAV,
|
||||
paradeBlueBucketUAV,
|
||||
paradeAlphaBucketUAV,
|
||||
vectorScopeBucketUAV,
|
||||
paradeUAV,
|
||||
vectorScopeUAV
|
||||
};
|
||||
|
||||
static UINT zero[] = { 0, 0, 0, 0, 0, 0, 0, 0 };
|
||||
|
||||
context->ClearUnorderedAccessViewUint(histogramRedBucketUAV, zero);
|
||||
context->ClearUnorderedAccessViewUint(histogramGreenBucketUAV, zero);
|
||||
context->ClearUnorderedAccessViewUint(histogramBlueBucketUAV, zero);
|
||||
context->ClearUnorderedAccessViewUint(vectorScopeBucketUAV, zero);
|
||||
context->ClearUnorderedAccessViewUint(paradeRedBucketUAV, zero);
|
||||
context->ClearUnorderedAccessViewUint(paradeGreenBucketUAV, zero);
|
||||
context->ClearUnorderedAccessViewUint(paradeBlueBucketUAV, zero);
|
||||
context->ClearUnorderedAccessViewUint(paradeAlphaBucketUAV, zero);
|
||||
|
||||
context->CSSetShaderResources(0, 1, &analysisSRV);
|
||||
|
||||
context->OMSetRenderTargets(1, (ID3D11RenderTargetView* const *)zero, NULL);
|
||||
context->CSSetUnorderedAccessViews(0, 8, histogramUAVs, NULL);
|
||||
context->CSSetShader(csHistogramGather, NULL, 0);
|
||||
context->Dispatch(SCREENWIDTH / 16, SCREENHEIGHT / 16, 1);
|
||||
context->CSSetShader(csHistogramMaximum, NULL, 0);
|
||||
context->Dispatch(16, 1, 1);
|
||||
context->CSSetShader(csHistogramSpread, NULL, 0);
|
||||
context->Dispatch(16, 16, 1);
|
||||
|
||||
context->CSSetUnorderedAccessViews(0, 8, paradeVectorscopeUAVs, NULL);
|
||||
context->CSSetShader(csParadeVectorscopeGather, NULL, 0);
|
||||
context->Dispatch(SCREENWIDTH / 16, SCREENHEIGHT / 16, 1);
|
||||
context->CSSetShader(csParadeVectorscopeMaximum, NULL, 0);
|
||||
context->Dispatch(16, 16, 1);
|
||||
context->CSSetShader(csParadeVectorscopeSpread, NULL, 0);
|
||||
context->Dispatch(16, 16, 1);
|
||||
|
||||
context->CSSetShaderResources(0, 1, (ID3D11ShaderResourceView* const*)zero);
|
||||
context->CSSetUnorderedAccessViews(0, 8, (ID3D11UnorderedAccessView* const *)zero, NULL);
|
||||
|
||||
context->CopyResource(histogramStagingTexture, histogramTexture);
|
||||
context->Map(histogramStagingTexture, 0, D3D11_MAP_READ, 0, &mappedResource);
|
||||
memcpy(histogram, mappedResource.pData, 4 * 256 * 256);
|
||||
context->Unmap(histogramStagingTexture, 0);
|
||||
|
||||
context->CopyResource(paradeStagingTexture, paradeTexture);
|
||||
context->Map(paradeStagingTexture, 0, D3D11_MAP_READ, 0, &mappedResource);
|
||||
memcpy(parade, mappedResource.pData, 4 * 4 * 256 * 256);
|
||||
context->Unmap(paradeStagingTexture, 0);
|
||||
|
||||
context->CopyResource(vectorScopeStagingTexture, vectorScopeTexture);
|
||||
context->Map(vectorScopeStagingTexture, 0, D3D11_MAP_READ, 0, &mappedResource);
|
||||
memcpy(vectorscope, mappedResource.pData, 4 * 256 * 256);
|
||||
context->Unmap(vectorScopeStagingTexture, 0);
|
||||
|
||||
if (SharedMemoryTool->SeekToRow >= 0)
|
||||
{
|
||||
auto row = SharedMemoryTool->SeekToRow;
|
||||
SharedMemoryTool->SeekToRow = -1;
|
||||
SoundSeekToRow(NULL, row);
|
||||
}
|
||||
|
||||
if (SharedMemoryTool->DisplayTextureIndex >= 0)
|
||||
{
|
||||
int i = 0;
|
||||
for (auto texture : textureMap)
|
||||
{
|
||||
if (i++ != SharedMemoryTool->DisplayTextureIndex)
|
||||
continue;
|
||||
|
||||
texture.second->TEX->GetDesc(&displayDesc);
|
||||
displayDesc.Format = DXGI_FORMAT_R8G8B8A8_UINT;
|
||||
displayDesc.MipLevels = 1;
|
||||
displayDesc.BindFlags |= D3D11_BIND_UNORDERED_ACCESS;
|
||||
device->CreateTexture2D(&displayDesc, NULL, &displayRGBTexture);
|
||||
device->CreateTexture2D(&displayDesc, NULL, &displayATexture);
|
||||
displayDesc.Usage = D3D11_USAGE_STAGING;
|
||||
displayDesc.CPUAccessFlags = D3D11_CPU_ACCESS_READ;
|
||||
displayDesc.BindFlags = 0;
|
||||
displayDesc.MiscFlags = 0;
|
||||
device->CreateTexture2D(&displayDesc, NULL, &displayStagingTexture);
|
||||
device->CreateUnorderedAccessView(displayRGBTexture, NULL, &displayRGBUAV);
|
||||
device->CreateUnorderedAccessView(displayATexture, NULL, &displayAUAV);
|
||||
|
||||
context->CSSetShaderResources(0, 1, &texture.second->SRV);
|
||||
context->CSSetUnorderedAccessViews(1, 1, &displayRGBUAV, NULL);
|
||||
context->CSSetUnorderedAccessViews(2, 1, &displayAUAV, NULL);
|
||||
context->CSSetShader(csTextureViewer, NULL, 0);
|
||||
context->Dispatch(displayDesc.Width / 16, displayDesc.Height / 16, 1);
|
||||
context->CSSetUnorderedAccessViews(0, 3, (ID3D11UnorderedAccessView* const *)zero, NULL);
|
||||
context->CSSetShaderResources(0, 1, (ID3D11ShaderResourceView* const *)zero);
|
||||
|
||||
context->CopyResource(displayStagingTexture, displayRGBTexture);
|
||||
context->Map(displayStagingTexture, 0, D3D11_MAP_READ, 0, &mappedResource);
|
||||
auto pData = displayTextureData + 1;
|
||||
*(UINT*)(pData) = displayDesc.Width;
|
||||
pData += sizeof(UINT);
|
||||
*(UINT*)(pData) = displayDesc.Height;
|
||||
pData += sizeof(UINT);
|
||||
memcpy(pData, mappedResource.pData, mappedResource.RowPitch * displayDesc.Height);
|
||||
pData += mappedResource.RowPitch * displayDesc.Height;
|
||||
context->Unmap(displayStagingTexture, 0);
|
||||
|
||||
context->CopyResource(displayStagingTexture, displayATexture);
|
||||
context->Map(displayStagingTexture, 0, D3D11_MAP_READ, 0, &mappedResource);
|
||||
memcpy(pData, mappedResource.pData, mappedResource.RowPitch * displayDesc.Height);
|
||||
context->Unmap(displayStagingTexture, 0);
|
||||
|
||||
displayTextureData[0] = SharedMemoryTool->DisplayTextureIndex;
|
||||
displayStagingTexture->Release();
|
||||
displayRGBTexture->Release();
|
||||
displayATexture->Release();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void AuthoringDispose()
|
||||
{
|
||||
Log("AuthoringDispose");
|
||||
|
||||
UnmapViewOfFile(SharedMemoryTool);
|
||||
UnmapViewOfFile(SharedImage);
|
||||
UnmapViewOfFile(histogram);
|
||||
UnmapViewOfFile(parade);
|
||||
UnmapViewOfFile(vectorscope);
|
||||
UnmapViewOfFile(syncDataAudio);
|
||||
UnmapViewOfFile(syncOverrideData);
|
||||
UnmapViewOfFile(displayTextureData);
|
||||
|
||||
CloseHandle(SharedMemoryFileMapping);
|
||||
CloseHandle(AudioFileMapping);
|
||||
CloseHandle(ImageFileMapping);
|
||||
CloseHandle(HistogramFileMapping);
|
||||
CloseHandle(ParadeFileMapping);
|
||||
CloseHandle(VectorscopeFileMapping);
|
||||
CloseHandle(SyncDataFileMapping);
|
||||
CloseHandle(SyncOverrideDataFileMapping);
|
||||
CloseHandle(DisplayTextureFileMapping);
|
||||
}
|
||||
447
aquarium/src/intro/framework/codegen/intro_hlsl.g.h
Normal file
447
aquarium/src/intro/framework/codegen/intro_hlsl.g.h
Normal file
@@ -0,0 +1,447 @@
|
||||
/* File generated with Shader Minifier 1.1.3
|
||||
* http://www.ctrl-alt-test.fr
|
||||
*/
|
||||
#ifndef INTRO_HLSL_G_H_
|
||||
# define INTRO_HLSL_G_H_
|
||||
# define VAR_PI "k"
|
||||
# define VAR_TAU "D"
|
||||
# define VAR_CONV "T"
|
||||
# define VAR_F "y"
|
||||
# define VAR_K "z"
|
||||
# define VAR_O2D0 "f"
|
||||
# define VAR_S0 "x"
|
||||
# define VAR_T2D0 "i"
|
||||
# define VAR_T2D1 "d"
|
||||
# define VAR_T2D2 "o"
|
||||
# define VAR_T2D3 "e"
|
||||
# define VAR_T2D4 "r"
|
||||
# define VAR_T2D5 "m"
|
||||
|
||||
char merged_hlsl[] = "#define _ [numthreads(16,16,1)]\n"
|
||||
"struct Sync{float time;float3 cameraPos;float dummy1;float3 cameraAt;float dummy2;float3 cameraUp;};struct Hull{float3 position:c;int type:t;sample float3 world:w;float3 scale:s;sample float4 o:SV_Position;float3x3 rotate:r;};struct Cam{float4 _d:d;float4 _e:e;float4 _u:u;};RWTexture2D<float4> f:register(u0);"
|
||||
"Texture2D i:register(t0),d:register(t1),o:register(t2),e:register(t3),r:register(t4),m:register(t5);"
|
||||
"SamplerState x:register(s0);cbuffer sb:register(b0){Sync _s;};cbuffer cb:register(b1){Cam _c;};cbuffer cb:register(b2){Cam _l;};"
|
||||
"float2 c(float2 f,float2 y)"
|
||||
"{"
|
||||
"return f-y*floor(f/y);"
|
||||
"}"
|
||||
"float s(float f,float y)"
|
||||
"{"
|
||||
"return f-y*floor(f/y);"
|
||||
"}\n"
|
||||
"#define HASHSCALE1 443.8975\n"
|
||||
"#define HASHSCALE3 float3(443.897,441.423,437.195)\n"
|
||||
"#define HASHSCALE4 float4(443.897,441.423,437.195,444.129)\n"
|
||||
"float c(float f)"
|
||||
"{"
|
||||
"float3 x=frac(f*HASHSCALE1);"
|
||||
"x+=dot(x,x.yzx+19.19);"
|
||||
"return frac((x.x+x.y)*x.z);"
|
||||
"}"
|
||||
"float s(float2 f)"
|
||||
"{"
|
||||
"float3 x=frac(f.xyx*HASHSCALE1);"
|
||||
"x+=dot(x,x.yzx+19.19);"
|
||||
"return frac((x.x+x.y)*x.z);"
|
||||
"}"
|
||||
"float t(float3 f)"
|
||||
"{"
|
||||
"return f=frac(f*HASHSCALE1),f+=dot(f,f.yzx+19.19),frac((f.x+f.y)*f.z);"
|
||||
"}"
|
||||
"float2 p(float f)"
|
||||
"{"
|
||||
"float3 x=frac(f*HASHSCALE3);"
|
||||
"x+=dot(x,x.yzx+19.19);"
|
||||
"return frac((x.xx+x.yz)*x.zy);"
|
||||
"}"
|
||||
"float2 l(float2 f)"
|
||||
"{"
|
||||
"float3 x=frac(f.xyx*HASHSCALE3);"
|
||||
"x+=dot(x,x.yzx+19.19);"
|
||||
"return frac((x.xx+x.yz)*x.zy);"
|
||||
"}"
|
||||
"float2 h(float3 f)"
|
||||
"{"
|
||||
"return f=frac(f*HASHSCALE3),f+=dot(f,f.yzx+19.19),frac((f.xx+f.yz)*f.zy);"
|
||||
"}"
|
||||
"float3 n(float f)"
|
||||
"{"
|
||||
"float3 x=frac(f*HASHSCALE3);"
|
||||
"x+=dot(x,x.yzx+19.19);"
|
||||
"return frac((x.xxy+x.yzz)*x.zyx);"
|
||||
"}"
|
||||
"float3 H(float2 f)"
|
||||
"{"
|
||||
"float3 x=frac(f.xyx*HASHSCALE3);"
|
||||
"x+=dot(x,x.yxz+19.19);"
|
||||
"return frac((x.xxy+x.yzz)*x.zyx);"
|
||||
"}"
|
||||
"float3 w(float3 f)"
|
||||
"{"
|
||||
"return f=frac(f*HASHSCALE3),f+=dot(f,f.yxz+19.19),frac((f.xxy+f.yxx)*f.zyx);"
|
||||
"}"
|
||||
"float4 a(float f)"
|
||||
"{"
|
||||
"float4 x=frac(f*HASHSCALE4);"
|
||||
"x+=dot(x,x.wzxy+19.19);"
|
||||
"return frac((x.xxyz+x.yzzw)*x.zywx);"
|
||||
"}"
|
||||
"float4 g(float2 f)"
|
||||
"{"
|
||||
"float4 x=frac(f.xyxy*HASHSCALE4);"
|
||||
"x+=dot(x,x.wzxy+19.19);"
|
||||
"return frac((x.xxyz+x.yzzw)*x.zywx);"
|
||||
"}"
|
||||
"float4 C(float3 f)"
|
||||
"{"
|
||||
"float4 x=frac(f.xyzx*HASHSCALE4);"
|
||||
"x+=dot(x,x.wzxy+19.19);"
|
||||
"return frac((x.xxyz+x.yzzw)*x.zywx);"
|
||||
"}"
|
||||
"float4 v(float4 f)"
|
||||
"{"
|
||||
"return f=frac(f*HASHSCALE4),f+=dot(f,f.wzxy+19.19),frac((f.xxyz+f.yzzw)*f.zywx);"
|
||||
"}"
|
||||
"float u(in float3 f)"
|
||||
"{"
|
||||
"float3 x=floor(f),y=frac(f);"
|
||||
"y=y*y*(3-2*y);"
|
||||
"return lerp(lerp(lerp(t(x+float3(0,0,0)),t(x+float3(1,0,0)),y.x),lerp(t(x+float3(0,1,0)),t(x+float3(1,1,0)),y.x),y.y),lerp(lerp(t(x+float3(0,0,1)),t(x+float3(1,0,1)),y.x),lerp(t(x+float3(0,1,1)),t(x+float3(1,1,1)),y.x),y.y),y.z);"
|
||||
"}"
|
||||
"float3 S(in float f)"
|
||||
"{"
|
||||
"float x=floor(f),y=frac(f);"
|
||||
"y=y*y*(3-2*y);"
|
||||
"return lerp(n(x),n(x+1),y);"
|
||||
"}"
|
||||
"void C(inout float2 f,float x)"
|
||||
"{"
|
||||
"f=cos(x)*f+sin(x)*float2(f.y,-f.x);"
|
||||
"}"
|
||||
"static const float y=.0535,z=.062,k=acos(-1),D=2*k;"
|
||||
"static const float3x3 T=float3x3(.05,.2,.05,.2,-1,.2,.05,.2,.05);"
|
||||
"float V(float2 f)"
|
||||
"{"
|
||||
"float2 x=floor(f),y;"
|
||||
"f-=x;"
|
||||
"float3 i=1;"
|
||||
"for(int r=-1;r<=1;r++)"
|
||||
"for(int m=-1;m<=1;m++)"
|
||||
"y=float2(m,r),y+=l(x+y)-f,i.z=dot(y,y),i.y=max(i.x,min(i.y,i.z)),i.x=min(i.x,i.z);"
|
||||
"return i.y-i.x;"
|
||||
"}"
|
||||
"_ "
|
||||
"void cs_Stone(uint3 x:SV_DispatchThreadID)"
|
||||
"{"
|
||||
"float2 y;"
|
||||
"f.GetDimensions(y.x,y.y);"
|
||||
"float2 e=x.xy/y;"
|
||||
"float d=V(e*5-.35)*.6+V((e.yx+.5)*10)*.3+(1-V(e*25))*.075+V(e*60)*.025;"
|
||||
"float4 r=i[x.xy];"
|
||||
"r.z=d;"
|
||||
"f[x.xy]=r;"
|
||||
"}"
|
||||
"float2 A(int2 f)"
|
||||
"{"
|
||||
"float y=2048;"
|
||||
"f=c(f,y);"
|
||||
"float2 x=i[f].xy;"
|
||||
"return float2(x.x,max(x.y,.25*step(.98,s(f/y))));"
|
||||
"}"
|
||||
"float2 b(int2 f)"
|
||||
"{"
|
||||
"float2 x=float2(0,0);"
|
||||
"for(int y=-1;y<=1;y++)"
|
||||
"for(int i=-1;i<=1;i++)"
|
||||
"x+=A(f+int2(i,y))*T[i+1][y+1];"
|
||||
"return x;"
|
||||
"}"
|
||||
"_ "
|
||||
"void cs_Coral(uint3 x:SV_DispatchThreadID)"
|
||||
"{"
|
||||
"float2 r=A(x.xy),e=b(x.xy);"
|
||||
"float d=r.x*r.y*r.y;"
|
||||
"r.x+=e.x-d+y*(1-r.x);"
|
||||
"r.y+=.5*e.y+d-(z+y)*r.y;"
|
||||
"float4 c=i[x.xy];"
|
||||
"c.xy=r;"
|
||||
"f[x.xy]=c;"
|
||||
"}"
|
||||
"_ "
|
||||
"void cs_Caustics(uint3 x:SV_DispatchThreadID)"
|
||||
"{"
|
||||
"float2 y;"
|
||||
"f.GetDimensions(y.x,y.y);"
|
||||
"float d=1315,r=1,z=1,e;"
|
||||
"for(float2 m=x.xy/y,o=c(m*D,D)-d,s=float2(o);z<=5;z++)"
|
||||
"e=_s.time*(30-1.5/z),s=o+float2(cos(e-s.x)+sin(e+s.y),sin(e-s.y)+cos(e+s.x)),r+=d/length(float2(o.x/sin(e+s.x),o.y/cos(e+s.y)));"
|
||||
"r=pow(1-r/z,4);"
|
||||
"float4 l=i[x.xy];"
|
||||
"l.w=r;"
|
||||
"f[x.xy]=l;"
|
||||
"}"
|
||||
"void Camera(out float4 f:d0,out float4 x:e0,out float4 y:u0,out float4 o:d1,out float4 i:e1,out float4 e:u1)"
|
||||
"{"
|
||||
"f=float4(normalize(_s.cameraAt-_s.cameraPos),0),x=float4(_s.cameraPos,0),y=float4(normalize(_s.cameraUp),0),o=float4(0,-1,0,0),i=float4(0,300,0,0),e=float4(0,0,1,0);"
|
||||
"}"
|
||||
"float4 A(float3 f,Cam x)"
|
||||
"{"
|
||||
"float3 i=x._u.xyz,y=x._d.xyz,z=x._e.xyz,e=cross(i,y),o=cross(y,e);"
|
||||
"return mul(mul(float4(f,1),transpose(float4x4(e,-dot(e,z),o,-dot(o,z),y,-dot(y,z),0,0,0,1))),float4x4(1,0,0,0,0,1.6,0,0,0,0,1,1,0,0,-1,0));"
|
||||
"}"
|
||||
"void vs_DrawHulls(uint f:SV_VertexID,out Hull x)"
|
||||
"{"
|
||||
"x.rotate=float3x3(1,0,0,0,1,0,0,0,1);"
|
||||
"if(f<4)"
|
||||
"x.position=float3((f<2)*((f>0)-.5)*2,-(f==3),f==2)*float3(200,100,125),x.scale=(abs(x.position)==0)*float3(390,190,240)+10,x.type=f==3?3:2;"
|
||||
"else"
|
||||
" if(f<23)"
|
||||
"{"
|
||||
"x.position=(H(float2(f.x,10))-.5)*float3(200,-90,67);"
|
||||
"x.position.y-=50;"
|
||||
"x.scale=s(float2(f.x,3))*60+10;"
|
||||
"x.type=1;"
|
||||
"float i=s(float2(f.x,2)),y,z;"
|
||||
"sincos(i,y,z);"
|
||||
"x.rotate=float3x3(z,0,y,0,1,0,-y,0,z);"
|
||||
"}"
|
||||
"else"
|
||||
"{"
|
||||
"x.position=normalize(H(float2(f.x+7,5))-.5);"
|
||||
"x.position*=(s(float2(f.x,5))*.5+.5)*float3(200,100,125);"
|
||||
"C(x.position.xz,_s.time*length(x.position.xz)*.01);"
|
||||
"x.type=0;"
|
||||
"float i=s(float2(f.x,2))+(s(float2(f.x+11,3))-.5)*_s.time*10,y,z;"
|
||||
"sincos(i,y,z);"
|
||||
"x.rotate=float3x3(z,0,y,0,1,0,-y,0,z);"
|
||||
"x.scale=s(float2(f.x,4))*2+.5;"
|
||||
"x.scale.x*=3;"
|
||||
"x.scale.z*=.2;"
|
||||
"}"
|
||||
"x.o=0;"
|
||||
"x.world=0;"
|
||||
"}"
|
||||
"[maxvertexcount(14)]"
|
||||
"void gs_DrawHulls(point Hull f[1],inout TriangleStream<Hull> x)"
|
||||
"{"
|
||||
"Hull y=f[0];"
|
||||
"for(uint r=0;r<14;++r)"
|
||||
"{"
|
||||
"uint z=1<<r;"
|
||||
"float3 i=float3((10362&z)!=0,(687&z)!=0,(12771&z)!=0)-.5f;"
|
||||
"i*=y.scale;"
|
||||
"i=mul(i,y.rotate);"
|
||||
"i+=y.position;"
|
||||
"y.world=i;"
|
||||
"y.o=A(i,_c);"
|
||||
"x.Append(y);"
|
||||
"}"
|
||||
"x.RestartStrip();"
|
||||
"}"
|
||||
"float E(float3 f)"
|
||||
"{"
|
||||
"return max(max(f.x,f.y),f.z);"
|
||||
"}"
|
||||
"float E(float3 f,float3 y)"
|
||||
"{"
|
||||
"float3 x=abs(f)-y;"
|
||||
"return length(max(x,0))+E(min(x,0));"
|
||||
"}"
|
||||
"float H(in float3 f,in float3 x)"
|
||||
"{"
|
||||
"float i=length(f/x);"
|
||||
"return i*(i-1)/length(f/(x*x));"
|
||||
"}"
|
||||
"float A(float f,float x,float y)"
|
||||
"{"
|
||||
"float z=clamp(.5+.5*(x-f)/y,0,1);"
|
||||
"return lerp(x,f,z)-y*z*(1-z);"
|
||||
"}"
|
||||
"float L(float2 f)"
|
||||
"{"
|
||||
"float2 x=abs(f);"
|
||||
"return min(max(max(min(abs(s(f.x+.067,.134)-.067),max(x.x,x.y)-.1),-min(length(f-float2(0,.03))-.06,max(x.x,abs(f.y+.02)-.03)-.04)),abs(x.x+x.y)-.4),abs(abs(x.x+x.y)-.41)+.01)-.02;"
|
||||
"}"
|
||||
"float L(in float3 f,in float y)"
|
||||
"{"
|
||||
"float x=L(f.xy);"
|
||||
"float2 i=float2(x,abs(f.z)-y);"
|
||||
"return min(max(i.x,i.y),0)+length(max(i,0));"
|
||||
"}"
|
||||
"float S(Hull f,float3 y)"
|
||||
"{"
|
||||
"float3 x=y;"
|
||||
"x-=f.position;"
|
||||
"x=mul(x,transpose(f.rotate));"
|
||||
"float i=0;"
|
||||
"if(f.type==1)"
|
||||
"{"
|
||||
"x/=f.scale.x;"
|
||||
"float e=.3*(u(x*7)-.5)+.1*(u(x*20)-.5)+.02*(u(x*50)-.5)+.008*(u(x*125)-.5)+.001*(u(x*500)-.5);"
|
||||
"i=length(x)-.5+e*.5;"
|
||||
"i*=f.scale.x;"
|
||||
"}"
|
||||
"else"
|
||||
" if(f.type>=2)"
|
||||
"{"
|
||||
"float e=u(x*.1)-.5+.5*(u(x*1)-.5)+.3*(u(x*2)-.5)+.1*(u(x*5)-.5);"
|
||||
"i=E(x,f.scale*.5)-e*.5;"
|
||||
"}"
|
||||
"else"
|
||||
" i=H(x,f.scale*float3(.4,.5,.5)),i=A(i,E(x+float3(f.scale.x*.85,0,0),f.scale*float3(.0625,.1,.05)),4);"
|
||||
"return i;"
|
||||
"}"
|
||||
"float3 V(Hull f,float3 x)"
|
||||
"{"
|
||||
"float2 y=float2(.001,0);"
|
||||
"return normalize(float3(S(f,x+y.xyy)-S(f,x-y.xyy),S(f,x+y.yxy)-S(f,x-y.yxy),S(f,x+y.yyx)-S(f,x-y.yyx)));"
|
||||
"}"
|
||||
"bool A(in Hull f,in int x,out float3 y,out float z)"
|
||||
"{"
|
||||
"y=normalize(f.world-_c._e.xyz);"
|
||||
"float i=0,e=500;"
|
||||
"for(int r=0;r<x;++r)"
|
||||
"{"
|
||||
"float d=S(f,f.world+i*y);"
|
||||
"i+=d;"
|
||||
"if(d<e)"
|
||||
"z=i,e=d;"
|
||||
"if(i>length(f.scale)||d<.001)"
|
||||
"{"
|
||||
"break;"
|
||||
"}"
|
||||
"}"
|
||||
"return e<.01;"
|
||||
"}"
|
||||
"void ps_DrawHulls(in Hull f,out float x:SV_Depth,out float4 i:SV_Target0,out float4 r:SV_Target1,out float4 y:SV_Target2)"
|
||||
"{"
|
||||
"float3 z;"
|
||||
"float e;"
|
||||
"i=r=y=0;"
|
||||
"x=1;"
|
||||
"if(A(f,48,z,e))"
|
||||
"{"
|
||||
"float3 o=f.world+e*z,m=V(f,o);"
|
||||
"x=length(o-_c._e.xyz)/500;"
|
||||
"i=float4(f.type,0,0,1);"
|
||||
"r=float4(o,0);"
|
||||
"y=float4(m,0);"
|
||||
"return;"
|
||||
"}"
|
||||
"discard;"
|
||||
"}"
|
||||
"float ps_DrawDepth(in Hull f,out float x:SV_Depth):SV_Target0"
|
||||
"{"
|
||||
"float3 y;"
|
||||
"float z;"
|
||||
"x=0;"
|
||||
"if(A(f,24,y,z))"
|
||||
"{"
|
||||
"float3 i=f.world+z*y;"
|
||||
"x=length(i-_c._e.xyz)/500;"
|
||||
"return exp(80*x);"
|
||||
"}"
|
||||
"discard;"
|
||||
"}"
|
||||
"float C(float f,float x,float y,float i)"
|
||||
"{"
|
||||
"return x+log(f+y*exp(i-x));"
|
||||
"}"
|
||||
"float a(float2 f,float2 y)"
|
||||
"{"
|
||||
"const float i[7]={.006,.061,.242,.382,.242,.061,.006};"
|
||||
"float2 e=f-3*y.xy;"
|
||||
"float z=0;"
|
||||
"for(int s=0;s<7;++s)"
|
||||
"z+=r.Sample(x,e+s*y.xy).x*i[s];"
|
||||
"return z;"
|
||||
"}"
|
||||
"float ps_BlurH(in float2 f:TEXCOORD):SV_Target0"
|
||||
"{"
|
||||
"float x,y;"
|
||||
"r.GetDimensions(x,y);"
|
||||
"return a(f,float2(1/x,0));"
|
||||
"}"
|
||||
"float ps_BlurV(in float2 f:TEXCOORD):SV_Target0"
|
||||
"{"
|
||||
"float x,y;"
|
||||
"r.GetDimensions(x,y);"
|
||||
"return a(f,float2(0,1/y));"
|
||||
"}"
|
||||
"void vs_ScreenQuad(uint f:SV_VertexID,out float2 x:TEXCOORD,out float4 y:SV_Position)"
|
||||
"{"
|
||||
"x=float2(f/2,f%2),y=float4(x*2-1,0,1),x.y=1-x.y;"
|
||||
"}"
|
||||
"float C(in float2 f,float y,float z)"
|
||||
"{"
|
||||
"float3 i=d.Sample(x,f).xyz,r=o.Sample(x,f).xyz;"
|
||||
"float m=0,s=0;"
|
||||
"for(int c=0;c<32;++c)"
|
||||
"{"
|
||||
"float3 H=S(c)-.5;"
|
||||
"float l=dot(H,r);"
|
||||
"if(l<0)"
|
||||
"H*=-1,l*=-1;"
|
||||
"s+=l;"
|
||||
"H=i+y*H;"
|
||||
"float3 p=A(H,_c).xyw;"
|
||||
"p.xy=p.xy/p.z*float2(.5,-.5)+.5;"
|
||||
"float n=e.Sample(x,p.xy).x*500+.3,D=z*max(length(H-_s.cameraPos)-n,0)/y;"
|
||||
"m+=l/(1+D*D);"
|
||||
"}"
|
||||
"return saturate(m/s);"
|
||||
"}"
|
||||
"float ps_AmbientOcclussion(in float2 f:TEXCOORD):SV_Target0"
|
||||
"{"
|
||||
"return C(f,.3,50)*C(f,2,10)*C(f,5,5);"
|
||||
"}"
|
||||
"float b(float3 f,float3 y)"
|
||||
"{"
|
||||
"float3 i=float3(0,300,0)-f;"
|
||||
"float z=length(i)/500;"
|
||||
"i=normalize(i);"
|
||||
"float3 e=A(f,_l).xyw;"
|
||||
"e.xy=e.xy/e.z*float2(.5,-.5)+.5;"
|
||||
"float m=exp(-80*z)*r.Sample(x,e.xy).x,o=max(dot(y,i),0);"
|
||||
"return min(m,o)*1.2;"
|
||||
"}"
|
||||
"float O(float3 f)"
|
||||
"{"
|
||||
"float x=0;"
|
||||
"float3 y=(_c._e.xyz-f)/128;"
|
||||
"float z=.7;"
|
||||
"for(int i=0;i<128;++i)"
|
||||
"x+=lerp(1,b(f,normalize(float3(0,300,0)-f)),z),f+=y;"
|
||||
"return pow(x/128,8);"
|
||||
"}"
|
||||
"float3 E(float f,float3 y,float3 i)"
|
||||
"{"
|
||||
"if(f==0)"
|
||||
"return float3(.3,.7,.3);"
|
||||
"else"
|
||||
" if(f==1)"
|
||||
"return pow(m.Sample(x,1+y.yz*.15).z*abs(i.x)+m.Sample(x,1+y.xz*.15).z*abs(i.y)+m.Sample(x,1+y.xy*.15).z*abs(i.z),2)*float3(.8,.2,.1);"
|
||||
"else"
|
||||
" if(f==2)"
|
||||
"return float3(0,.05,.1);"
|
||||
"else"
|
||||
" if(f==3)"
|
||||
"return m.Sample(x,1+y.xz*.2).z*float3(.4,.2,.1);"
|
||||
"return 1;"
|
||||
"}"
|
||||
"float4 ps_PostProcess(in float2 f:TEXCOORD):SV_Target0"
|
||||
"{"
|
||||
"float3 y=d.Sample(x,f).xyz,z=o.Sample(x,f).xyz,r=E(i.Sample(x,f).x,y,z);"
|
||||
"float c=pow(m.Sample(x,y.xz*.02).w+.5,4)*max(0,z.y),s=_s.time,H=O(y),l=e.Sample(x,f).x,D=1,t=b(y,z);"
|
||||
"float3 u=r*l*H*max(t,.1);"
|
||||
"u+=lerp(.01,c,t)*H;"
|
||||
"float p=length(_c._e.xyz-y)/500;"
|
||||
"u=lerp(u,float3(.05,.1,.3),p);"
|
||||
"return float4(u*D,1);"
|
||||
"}"
|
||||
"float4 ps_ToGamma(in float2 f:TEXCOORD):SV_Target0"
|
||||
"{"
|
||||
"return i.SampleLevel(x,f,1);"
|
||||
"}";
|
||||
|
||||
#endif // INTRO_HLSL_G_H_
|
||||
698
aquarium/src/intro/framework/codegen/merged.hlsl
Normal file
698
aquarium/src/intro/framework/codegen/merged.hlsl
Normal file
@@ -0,0 +1,698 @@
|
||||
struct Sync
|
||||
{
|
||||
float time;
|
||||
float3 cameraPos;
|
||||
float dummy1;
|
||||
float3 cameraAt;
|
||||
float dummy2;
|
||||
float3 cameraUp;
|
||||
};
|
||||
|
||||
struct Hull
|
||||
{
|
||||
float3 position : c;
|
||||
int type : t;
|
||||
sample float3 world : w;
|
||||
float3 scale : s;
|
||||
sample float4 o : SV_Position;
|
||||
float3x3 rotate : r;
|
||||
};
|
||||
|
||||
struct Cam
|
||||
{
|
||||
float4 _d : d;
|
||||
float4 _e : e;
|
||||
float4 _u : u;
|
||||
};
|
||||
|
||||
RWTexture2D<float4> o2d0 : register(u0);
|
||||
Texture2D t2d0 : register(t0);
|
||||
Texture2D t2d1 : register(t1);
|
||||
Texture2D t2d2 : register(t2);
|
||||
Texture2D t2d3 : register(t3);
|
||||
Texture2D t2d4 : register(t4);
|
||||
Texture2D t2d5 : register(t5);
|
||||
SamplerState s0 : register(s0);
|
||||
|
||||
cbuffer sb : register(b0) { Sync _s; };
|
||||
cbuffer cb : register(b1) { Cam _c; };
|
||||
cbuffer cb : register(b2) { Cam _l; };
|
||||
|
||||
float2 mod2(float2 x, float2 y)
|
||||
{
|
||||
return x - y * floor(x / y);
|
||||
}
|
||||
|
||||
float mod(float x, float y)
|
||||
{
|
||||
return x - y * floor(x / y);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#define HASHSCALE1 443.8975
|
||||
#define HASHSCALE3 float3(443.897, 441.423, 437.195)
|
||||
#define HASHSCALE4 float4(443.897, 441.423, 437.195, 444.129)
|
||||
|
||||
|
||||
|
||||
float hash11(float p)
|
||||
{
|
||||
float3 p3 = frac(p * HASHSCALE1);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.x + p3.y) * p3.z);
|
||||
}
|
||||
|
||||
|
||||
|
||||
float hash12(float2 p)
|
||||
{
|
||||
float3 p3 = frac(p.xyx * HASHSCALE1);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.x + p3.y) * p3.z);
|
||||
}
|
||||
|
||||
|
||||
|
||||
float hash13(float3 p3)
|
||||
{
|
||||
p3 = frac(p3 * HASHSCALE1);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.x + p3.y) * p3.z);
|
||||
}
|
||||
|
||||
|
||||
|
||||
float2 hash21(float p)
|
||||
{
|
||||
float3 p3 = frac(p * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.xx + p3.yz)*p3.zy);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
float2 hash22(float2 p)
|
||||
{
|
||||
float3 p3 = frac(p.xyx * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.xx + p3.yz)*p3.zy);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
float2 hash23(float3 p3)
|
||||
{
|
||||
p3 = frac(p3 * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.xx + p3.yz)*p3.zy);
|
||||
}
|
||||
|
||||
|
||||
|
||||
float3 hash31(float p)
|
||||
{
|
||||
float3 p3 = frac(p * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.xxy + p3.yzz)*p3.zyx);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
float3 hash32(float2 p)
|
||||
{
|
||||
float3 p3 = frac(p.xyx * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yxz + 19.19);
|
||||
return frac((p3.xxy + p3.yzz)*p3.zyx);
|
||||
}
|
||||
|
||||
|
||||
|
||||
float3 hash33(float3 p3)
|
||||
{
|
||||
p3 = frac(p3 * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yxz + 19.19);
|
||||
return frac((p3.xxy + p3.yxx)*p3.zyx);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
float4 hash41(float p)
|
||||
{
|
||||
float4 p4 = frac(p * HASHSCALE4);
|
||||
p4 += dot(p4, p4.wzxy + 19.19);
|
||||
return frac((p4.xxyz + p4.yzzw)*p4.zywx);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
float4 hash42(float2 p)
|
||||
{
|
||||
float4 p4 = frac(p.xyxy * HASHSCALE4);
|
||||
p4 += dot(p4, p4.wzxy + 19.19);
|
||||
return frac((p4.xxyz + p4.yzzw)*p4.zywx);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
float4 hash43(float3 p)
|
||||
{
|
||||
float4 p4 = frac(p.xyzx * HASHSCALE4);
|
||||
p4 += dot(p4, p4.wzxy + 19.19);
|
||||
return frac((p4.xxyz + p4.yzzw)*p4.zywx);
|
||||
}
|
||||
|
||||
|
||||
|
||||
float4 hash44(float4 p4)
|
||||
{
|
||||
p4 = frac(p4 * HASHSCALE4);
|
||||
p4 += dot(p4, p4.wzxy + 19.19);
|
||||
return frac((p4.xxyz + p4.yzzw)*p4.zywx);
|
||||
}
|
||||
|
||||
|
||||
float noise13( in float3 x )
|
||||
{
|
||||
float3 p = floor(x);
|
||||
float3 f = frac(x);
|
||||
f = f*f*(3.0-2.0*f);
|
||||
|
||||
return lerp(lerp(lerp( hash13(p+float3(0,0,0)),
|
||||
hash13(p+float3(1,0,0)),f.x),
|
||||
lerp( hash13(p+float3(0,1,0)),
|
||||
hash13(p+float3(1,1,0)),f.x),f.y),
|
||||
lerp(lerp( hash13(p+float3(0,0,1)),
|
||||
hash13(p+float3(1,0,1)),f.x),
|
||||
lerp( hash13(p+float3(0,1,1)),
|
||||
hash13(p+float3(1,1,1)),f.x),f.y),f.z);
|
||||
}
|
||||
|
||||
float3 noise31( in float x )
|
||||
{
|
||||
float p = floor(x);
|
||||
float f = frac(x);
|
||||
f = f*f*(3.0-2.0*f);
|
||||
return lerp(hash31(p), hash31(p+1),f);
|
||||
}
|
||||
|
||||
|
||||
void pR(inout float2 p, float a)
|
||||
{
|
||||
p = cos(a)*p+sin(a)*float2(p.y,-p.x);
|
||||
}
|
||||
static const float
|
||||
f = 0.0535,
|
||||
k = 0.062,
|
||||
PI = acos(-1),
|
||||
TAU = 2 * PI;
|
||||
|
||||
static const float3x3 conv = float3x3(.05, .2, 0.05, .2, -1, .2, .05, .2, .05);
|
||||
|
||||
float voronoi(float2 p)
|
||||
{
|
||||
float2 g = floor(p), o; p -= g;
|
||||
float3 d = 1;
|
||||
|
||||
for (int y = -1; y <= 1; y++)
|
||||
for (int x = -1; x <= 1; x++)
|
||||
o = float2(x, y),
|
||||
o += hash22(g + o) - p,
|
||||
d.z = dot(o, o),
|
||||
d.y = max(d.x, min(d.y, d.z)),
|
||||
d.x = min(d.x, d.z);
|
||||
|
||||
return d.y - d.x;
|
||||
}
|
||||
|
||||
|
||||
[numthreads(16, 16, 1)] void cs_Stone(uint3 i : SV_DispatchThreadID)
|
||||
{
|
||||
float2 dim;
|
||||
o2d0.GetDimensions(dim.x, dim.y);
|
||||
float2 p = i.xy / dim;
|
||||
float c =
|
||||
voronoi(p * 5. - .35) * .6 +
|
||||
voronoi((p.yx + .5) * 10.) * .3 +
|
||||
(1. - voronoi(p * 25.)) * .075 +
|
||||
voronoi(p * 60.) * .025;
|
||||
|
||||
float4 col = t2d0[i.xy];
|
||||
col.z = c;
|
||||
o2d0[i.xy] = col;
|
||||
}
|
||||
|
||||
float2 fab(int2 uv)
|
||||
{
|
||||
float dim = 2048.;
|
||||
uv = mod2(uv, dim);
|
||||
float2 ab = t2d0[uv].xy;
|
||||
return float2(ab.x, max(ab.y, 0.25*step(0.98, hash12(uv / dim))));
|
||||
}
|
||||
|
||||
float2 Laplace(int2 uv)
|
||||
{
|
||||
float2 result = float2(0, 0);
|
||||
|
||||
for (int y = -1; y <= 1; y++)
|
||||
for (int x = -1; x <= 1; x++)
|
||||
result += fab(uv + int2(x, y)) * conv[x + 1][y + 1];
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
[numthreads(16, 16, 1)] void cs_Coral(uint3 i : SV_DispatchThreadID)
|
||||
{
|
||||
float2 ab = fab(i.xy), Lab = Laplace(i.xy);
|
||||
float ab2 = ab.x * ab.y * ab.y;
|
||||
ab.x += Lab.x - ab2 + f * (1.0 - ab.x);
|
||||
ab.y += .5 * Lab.y + ab2 - (k + f) * ab.y;
|
||||
float4 col = t2d0[i.xy];
|
||||
col.xy = ab;
|
||||
o2d0[i.xy] = col;
|
||||
}
|
||||
|
||||
|
||||
[numthreads(16, 16, 1)] void cs_Caustics(uint3 i : SV_DispatchThreadID)
|
||||
{
|
||||
float2 dim;
|
||||
o2d0.GetDimensions(dim.x, dim.y);
|
||||
float d = 1315., c = 1., n = 1., t;
|
||||
for (float2 uv = i.xy / dim, p = mod2(uv*TAU, TAU) - d, z = float2(p); n <= 5.; n++)
|
||||
t = _s.time * (30. - (1.5 / n)),
|
||||
z = p + float2(cos(t - z.x) + sin(t + z.y),
|
||||
sin(t - z.y) + cos(t + z.x)),
|
||||
c += d / length(float2(p.x / sin(t + z.x),
|
||||
p.y / cos(t + z.y)));
|
||||
c = pow(1. - c / n, 4.);
|
||||
|
||||
float4 col = t2d0[i.xy];
|
||||
col.w = c;
|
||||
o2d0[i.xy] = col;
|
||||
}
|
||||
|
||||
void Camera(
|
||||
out float4 cd : d0,
|
||||
out float4 ce : e0,
|
||||
out float4 cu : u0,
|
||||
out float4 ld : d1,
|
||||
out float4 le : e1,
|
||||
out float4 lu : u1)
|
||||
{
|
||||
cd = float4(normalize(_s.cameraAt - _s.cameraPos), 0);
|
||||
ce = float4(_s.cameraPos, 0);
|
||||
cu = float4(normalize(_s.cameraUp), 0);
|
||||
ld = float4(0, -1, 0, 0);
|
||||
le = float4(0, 300, 0, 0);
|
||||
lu = float4(0, 0, 1, 0);
|
||||
}
|
||||
|
||||
float4 project(float3 v, Cam c)
|
||||
{
|
||||
float3
|
||||
u = c._u.xyz,
|
||||
z = c._d.xyz,
|
||||
e = c._e.xyz,
|
||||
x = cross(u, z),
|
||||
y = cross(z, x);
|
||||
|
||||
return mul(mul(float4(v, 1.0),
|
||||
transpose(float4x4(
|
||||
x, -dot(x, e),
|
||||
y, -dot(y, e),
|
||||
z, -dot(z, e),
|
||||
0, 0, 0, 1))),
|
||||
float4x4(
|
||||
1, 0, 0, 0,
|
||||
0, 1.6, 0, 0,
|
||||
0, 0, 1, 1,
|
||||
0, 0, -1, 0));
|
||||
}
|
||||
|
||||
void vs_DrawHulls(uint i : SV_VertexID, out Hull h)
|
||||
{
|
||||
h.rotate = float3x3(1, 0, 0, 0, 1, 0, 0, 0, 1);
|
||||
if (i < 4)
|
||||
{
|
||||
h.position = float3((i < 2)*((i > 0) - .5) * 2, -(i == 3), i == 2)*float3(200, 100, 125);
|
||||
h.scale = (abs(h.position) == 0) * float3(390, 190, 240) + 10;
|
||||
h.type = i == 3 ? 3 : 2;
|
||||
}
|
||||
else if (i < 23)
|
||||
{
|
||||
h.position = (hash32(float2(i.x, 10)) - 0.5) * float3(200, -90, 67);
|
||||
h.position.y -= 50;
|
||||
h.scale = hash12(float2(i.x, 3)) * 60 + 10;
|
||||
h.type = 1;
|
||||
float rot = hash12(float2(i.x, 2));
|
||||
float s, c;
|
||||
sincos(rot, s, c);
|
||||
h.rotate = float3x3(
|
||||
c, 0, s,
|
||||
0, 1, 0,
|
||||
-s, 0, c);
|
||||
}
|
||||
else
|
||||
{
|
||||
h.position = normalize(hash32(float2(i.x + 7, 5)) - 0.5);
|
||||
h.position *= (hash12(float2(i.x, 5))*.5 + .5) * float3(200, 100, 125);
|
||||
pR(h.position.xz, _s.time * length(h.position.xz) * 0.01);
|
||||
h.type = 0;
|
||||
float rot = hash12(float2(i.x, 2)) + (hash12(float2(i.x + 11, 3)) - 0.5) * _s.time * 10;
|
||||
float s, c;
|
||||
sincos(rot, s, c);
|
||||
h.rotate = float3x3(
|
||||
c, 0, s,
|
||||
0, 1, 0,
|
||||
-s, 0, c);
|
||||
h.scale = hash12(float2(i.x, 4)) * 2 + .5;
|
||||
h.scale.x *= 3;
|
||||
h.scale.z *= 0.2;
|
||||
}
|
||||
h.o = 0;
|
||||
h.world = 0;
|
||||
}
|
||||
|
||||
|
||||
[maxvertexcount(14)] void gs_DrawHulls(point Hull hulls[1], inout TriangleStream<Hull> o)
|
||||
{
|
||||
Hull h = hulls[0];
|
||||
for (uint i = 0; i < 14; ++i)
|
||||
{
|
||||
uint b = 1 << i;
|
||||
float3 v = float3(
|
||||
(0x287a & b) != 0,
|
||||
(0x02af & b) != 0,
|
||||
(0x31e3 & b) != 0) - 0.5f;
|
||||
|
||||
v *= h.scale;
|
||||
v = mul(v, h.rotate);
|
||||
v += h.position;
|
||||
|
||||
h.world = v;
|
||||
h.o = project(v, _c);
|
||||
o.Append(h);
|
||||
}
|
||||
o.RestartStrip();
|
||||
}
|
||||
|
||||
float vmax(float3 v) {
|
||||
return max(max(v.x, v.y), v.z);
|
||||
}
|
||||
|
||||
|
||||
float fBox(float3 p, float3 b) {
|
||||
float3 d = abs(p) - b;
|
||||
return length(max(d, 0)) + vmax(min(d, 0));
|
||||
}
|
||||
|
||||
float sdEllipsoid(in float3 p, in float3 r)
|
||||
{
|
||||
float k0 = length(p / r);
|
||||
return k0*(k0 - 1) / length(p / (r*r));
|
||||
}
|
||||
|
||||
float opSmoothUnion(float d1, float d2, float k)
|
||||
{
|
||||
float h = clamp(0.5 + 0.5*(d2 - d1) / k, 0.0, 1.0);
|
||||
return lerp(d2, d1, h) - k*h*(1.0 - h);
|
||||
}
|
||||
|
||||
float atz(float2 p)
|
||||
{
|
||||
float2 a = abs(p);
|
||||
return min(max(max(
|
||||
min(abs(mod(p.x + .067, .134) - .067), max(a.x, a.y) - .1),
|
||||
-min(length(p - float2(0, .03)) - .06, max(a.x, abs(p.y + .02) - .03) - .04)
|
||||
), abs(a.x + a.y) - .4), abs(abs(a.x + a.y) - .41) + .01) - 0.02;
|
||||
}
|
||||
|
||||
float atz3(in float3 p, in float h)
|
||||
{
|
||||
float d = atz(p.xy);
|
||||
float2 w = float2(d, abs(p.z) - h);
|
||||
return min(max(w.x, w.y), 0.0) + length(max(w, 0.0));
|
||||
}
|
||||
|
||||
float map(Hull h, float3 p)
|
||||
{
|
||||
float3 q = p;
|
||||
q -= h.position;
|
||||
q = mul(q, transpose(h.rotate));
|
||||
|
||||
float dist = 0;
|
||||
if (h.type == 1)
|
||||
{
|
||||
q /= h.scale.x;
|
||||
float fbm =
|
||||
0.3 * (noise13(q * 7) - .5) +
|
||||
0.1 * (noise13(q * 20) - .5) +
|
||||
0.02 * (noise13(q * 50) - .5) +
|
||||
0.008 * (noise13(q * 125) - .5) +
|
||||
0.001 * (noise13(q * 500) - .5);
|
||||
dist = length(q) - .5 + fbm*.5;
|
||||
dist *= h.scale.x;
|
||||
}
|
||||
else if (h.type >= 2)
|
||||
{
|
||||
float fbm =
|
||||
1.0 * (noise13(q * .1) - .5) +
|
||||
0.5 * (noise13(q * 1) - .5) +
|
||||
0.3 * (noise13(q * 2) - .5) +
|
||||
0.1 * (noise13(q * 5) - .5);
|
||||
dist = fBox(q, h.scale * .5) - fbm*.5;
|
||||
}
|
||||
else
|
||||
{
|
||||
dist = sdEllipsoid(q, h.scale*float3(.4, .5, .5));
|
||||
dist = opSmoothUnion(dist, fBox(q + float3(h.scale.x*.85, 0, 0), h.scale*float3(.0625, .1, .05)), 4);
|
||||
/*q /= h.scale.x;
|
||||
dist = atz3(q, 0.05) - 0.005;
|
||||
dist *= h.scale.x * 0.7;*/
|
||||
}
|
||||
return dist;
|
||||
}
|
||||
|
||||
float3 normal(Hull h, float3 p)
|
||||
{
|
||||
float2 e = float2(0.001, 0);
|
||||
return normalize(float3(
|
||||
map(h, p + e.xyy) - map(h, p - e.xyy),
|
||||
map(h, p + e.yxy) - map(h, p - e.yxy),
|
||||
map(h, p + e.yyx) - map(h, p - e.yyx)));
|
||||
}
|
||||
|
||||
bool raymarch(in Hull h, in int iters, out float3 rd, out float mint)
|
||||
{
|
||||
rd = normalize(h.world - _c._e.xyz);
|
||||
float t = 0.0, lastm = 500;
|
||||
for (int i = 0; i < iters; ++i)
|
||||
{
|
||||
float m = map(h, h.world + t * rd);
|
||||
t += m;
|
||||
if (m < lastm)
|
||||
{
|
||||
mint = t;
|
||||
lastm = m;
|
||||
}
|
||||
if (t > length(h.scale) || m < 0.001)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
return lastm < 0.01;
|
||||
}
|
||||
|
||||
|
||||
void ps_DrawHulls(in Hull h, out float d : SV_Depth, out float4 o0 : SV_Target0, out float4 o1 : SV_Target1, out float4 o2 : SV_Target2)
|
||||
{
|
||||
float3 rd;
|
||||
float t;
|
||||
o0 = o1 = o2 = 0; d = 1;
|
||||
if (raymarch(h, 48, rd, t))
|
||||
{
|
||||
float3 p = h.world + t * rd;
|
||||
float3 n = normal(h, p);
|
||||
d = length(p - _c._e.xyz) / 500;
|
||||
o0 = float4(h.type, 0, 0, 1);
|
||||
o1 = float4(p, 0);
|
||||
o2 = float4(n, 0);
|
||||
return;
|
||||
}
|
||||
discard;
|
||||
}
|
||||
|
||||
float ps_DrawDepth(in Hull h, out float d : SV_Depth) : SV_Target0
|
||||
{
|
||||
float3 rd;
|
||||
float t;
|
||||
d = 0;
|
||||
if (raymarch(h, 24, rd, t))
|
||||
{
|
||||
float3 p = h.world + t * rd;
|
||||
d = length(p - _c._e.xyz) / 500;
|
||||
return exp(80 * d);
|
||||
}
|
||||
discard;
|
||||
return 0;
|
||||
}
|
||||
|
||||
float log_conv(float x0, float X, float y0, float Y)
|
||||
{
|
||||
return X + log(x0 + (y0 * exp(Y - X)));
|
||||
}
|
||||
|
||||
float blur(float2 uv, float2 dirAndSize)
|
||||
{
|
||||
const float coeff[7] = { 0.006, 0.061, 0.242, 0.382, 0.242, 0.061, 0.006 };
|
||||
float2 s = uv - 3 * dirAndSize.xy;
|
||||
float accum = 0;
|
||||
for (int i = 0; i < 7; ++i)
|
||||
accum += t2d4.Sample(s0, s + i * dirAndSize.xy).x * coeff[i];
|
||||
return accum;
|
||||
}
|
||||
|
||||
|
||||
float ps_BlurH(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
float w,h;
|
||||
t2d4.GetDimensions(w, h);
|
||||
return blur(uv, float2(1/w,0));
|
||||
}
|
||||
|
||||
|
||||
float ps_BlurV(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
float w,h;
|
||||
t2d4.GetDimensions(w, h);
|
||||
return blur(uv, float2(0,1/h));
|
||||
}
|
||||
|
||||
void vs_ScreenQuad(uint i : SV_VertexID, out float2 uv : TEXCOORD, out float4 p : SV_Position)
|
||||
{
|
||||
uv = float2(i / 2, i % 2);
|
||||
p = float4(uv * 2 - 1, 0, 1);
|
||||
uv.y = 1 - uv.y;
|
||||
}
|
||||
|
||||
float ao(in float2 uv, float rad, float strength)
|
||||
{
|
||||
float3 ep = t2d1.Sample(s0, uv).xyz;
|
||||
float3 n = t2d2.Sample(s0, uv).xyz;
|
||||
float bl = 0;
|
||||
float i = 0;
|
||||
for (int j = 0; j < 32; ++j)
|
||||
{
|
||||
float3 se = noise31(j) - .5;
|
||||
float imp = dot(se, n);
|
||||
if (imp < 0)
|
||||
{
|
||||
se *= -1;
|
||||
imp *= -1;
|
||||
}
|
||||
i += imp;
|
||||
se = ep + rad * se;
|
||||
float3 ss4 = project(se, _c).xyw;
|
||||
ss4.xy = ss4.xy / ss4.z * float2(.5, -.5) + .5;
|
||||
float sz = t2d3.Sample(s0, ss4.xy).x * 500 + .3;
|
||||
float zd = strength*max(length(se - _s.cameraPos) - sz, 0) / rad;
|
||||
bl += imp / (1.0 + zd*zd);
|
||||
}
|
||||
return saturate(bl / i);
|
||||
}
|
||||
|
||||
|
||||
float ps_AmbientOcclussion(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
return ao(uv, 0.3, 50) * ao(uv, 2, 10) * ao(uv, 5, 5);
|
||||
}
|
||||
|
||||
float sampleLight(float3 p, float3 n)
|
||||
{
|
||||
float3 lv = float3(0, 300, 0) - p;
|
||||
float d = length(lv) / 500;
|
||||
lv = normalize(lv);
|
||||
|
||||
float3 luv = project(p, _l).xyw;
|
||||
luv.xy = luv.xy / luv.z * float2(.5, -.5) + .5;
|
||||
float s = exp(-80 * d)*t2d4.Sample(s0, luv.xy).x;
|
||||
float df = max(dot(n, lv), 0);
|
||||
|
||||
return min(s, df)*1.2;
|
||||
}
|
||||
|
||||
float fog(float3 p)
|
||||
{
|
||||
float l = 0;
|
||||
float3 rd = (_c._e.xyz - p) / 128;
|
||||
float intensity = 0.7;
|
||||
for (int i = 0; i < 128; ++i)
|
||||
{
|
||||
l += lerp(1, sampleLight(p, normalize(float3(0, 300, 0) - p)), intensity);
|
||||
p += rd;
|
||||
}
|
||||
|
||||
return pow(l / 128, 8);
|
||||
}
|
||||
|
||||
float3 colorize(float type, float3 p, float3 n)
|
||||
{
|
||||
if (type == 0)
|
||||
{
|
||||
return float3(.3, .7, .3);
|
||||
}
|
||||
else if (type == 1)
|
||||
{
|
||||
return
|
||||
pow(t2d5.Sample(s0, 1 + p.yz*.15).z*abs(n.x) +
|
||||
t2d5.Sample(s0, 1 + p.xz*.15).z*abs(n.y) +
|
||||
t2d5.Sample(s0, 1 + p.xy*.15).z*abs(n.z), 2)*
|
||||
float3(0.8, 0.2, 0.1);
|
||||
}
|
||||
else if (type == 2)
|
||||
{
|
||||
return float3(0.0, 0.05, 0.1);
|
||||
}
|
||||
else if (type == 3)
|
||||
{
|
||||
return t2d5.Sample(s0, 1 + p.xz*.2).z*float3(0.4, 0.2, 0.1);
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
float4 ps_PostProcess(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
float3 c1 = t2d1.Sample(s0, uv).xyz;
|
||||
float3 c2 = t2d2.Sample(s0, uv).xyz;
|
||||
float3 c0 = colorize(t2d0.Sample(s0, uv).x, c1, c2);
|
||||
float cx = pow(t2d5.Sample(s0, c1.xz*.02).w + .5,4) * max(0, c2.y);
|
||||
float t = _s.time;
|
||||
float f = fog(c1);
|
||||
float a = t2d3.Sample(s0, uv).x;
|
||||
float fade = 1.0;
|
||||
float l = sampleLight(c1, c2);
|
||||
float3 color = c0 * a * f * max(l, 0.1);
|
||||
color += lerp(0.01, cx, l) * f;
|
||||
|
||||
float df = length(_c._e.xyz - c1) / 500;
|
||||
color = lerp(color, float3(0.05, 0.1, 0.3), df);
|
||||
return float4(color * fade, 1);
|
||||
}
|
||||
|
||||
|
||||
float4 ps_ToGamma(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
return t2d0.SampleLevel(s0, uv, 1);
|
||||
}
|
||||
698
aquarium/src/intro/framework/codegen/merged.hlsl.meta
Normal file
698
aquarium/src/intro/framework/codegen/merged.hlsl.meta
Normal file
@@ -0,0 +1,698 @@
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|1
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|2
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|3
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|4
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|5
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|6
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|7
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|8
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|9
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|11
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|12
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|13
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|14
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|15
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|16
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|17
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|18
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|19
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|20
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|21
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|22
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|23
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|24
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|25
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|26
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\structs.hlsl|27
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|2
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|3
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|4
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|5
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|6
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|7
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|8
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|9
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|10
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|11
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|12
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|13
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|14
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\intro.hlsl|15
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|1
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|2
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|3
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|4
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|5
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|6
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|7
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|8
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|9
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|10
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|11
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|12
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|13
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|14
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|15
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|16
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|17
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|18
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|19
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|20
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|21
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|22
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|23
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|24
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|25
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|26
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|27
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|28
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|29
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|30
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|31
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|32
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|33
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|34
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|35
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|36
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|37
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|38
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|39
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|40
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|41
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|42
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|43
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|44
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|45
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|46
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|47
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|48
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|49
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|50
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|51
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|52
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|53
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|54
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|55
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|56
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|57
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|58
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|59
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|60
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|61
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|62
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|63
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|64
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|65
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|66
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|67
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|68
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|69
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|70
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|71
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|72
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|73
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|74
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|75
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|76
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|77
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|78
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|79
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|80
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|81
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|82
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|83
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|84
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|85
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|86
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|87
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|88
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|89
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|90
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|91
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|92
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|93
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|94
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|95
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|96
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|97
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|98
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|99
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|100
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|101
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|102
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|103
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|104
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|105
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|106
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|107
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|108
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|109
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|110
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|111
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|112
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|113
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|114
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|115
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|116
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|117
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|118
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|119
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|120
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|121
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|122
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|123
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|124
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|125
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|126
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|127
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|128
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|129
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|130
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|131
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|132
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|133
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|134
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|135
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|136
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|137
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|138
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|139
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|140
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|141
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|142
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|143
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|144
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|145
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|146
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|147
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|148
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|149
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|150
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|151
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|152
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|153
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|154
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|155
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|156
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|157
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|158
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|159
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|160
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|161
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|162
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|163
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|164
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|165
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|166
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|167
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|168
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|169
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|170
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|171
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|172
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\functions.hlsl|173
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|1
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|2
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|3
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|4
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|5
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|6
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|7
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|8
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|9
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|10
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|11
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|12
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|13
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|14
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|15
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|16
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|17
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|18
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|19
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|20
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|21
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|22
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|23
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|24
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|25
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|26
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|27
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|28
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|29
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|30
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|31
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|32
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|33
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|34
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|35
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|36
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|37
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|38
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|39
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|40
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|41
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|42
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|43
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|44
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|45
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|46
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|47
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|48
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|49
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|50
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|51
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|52
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|53
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|54
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|55
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|56
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|57
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|58
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|59
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|60
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|61
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|62
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|63
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|64
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|65
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|66
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|67
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|68
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|69
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|70
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|71
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|72
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|73
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|74
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|75
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|76
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|77
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|78
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|79
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|80
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|81
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|82
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|83
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|84
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|85
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|86
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|87
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|88
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|89
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\textures.hlsl|90
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|1
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|2
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|3
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|4
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|5
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|6
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|7
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|8
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|9
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|10
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|11
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|12
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|13
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|14
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|15
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|16
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|17
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|18
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|19
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|20
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|21
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|22
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|23
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|24
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|25
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|26
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|27
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|28
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|29
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|30
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|31
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|32
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|33
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|34
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|35
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|36
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|37
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\camera.hlsl|38
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|1
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|2
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|3
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|4
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|5
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|6
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|7
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|8
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|9
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|10
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|11
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|12
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|13
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|14
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|15
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|16
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|17
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|18
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|19
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|20
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|21
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|22
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|23
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|24
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|25
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|26
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|27
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|28
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|29
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|30
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|31
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|32
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|33
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|34
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|35
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|36
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|37
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|38
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|39
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|40
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|41
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|42
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|43
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|44
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|45
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|46
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|47
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|48
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|49
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|50
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|51
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|52
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|53
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|54
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|55
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|56
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|57
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|58
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|59
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|60
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|61
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|62
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|63
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|64
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|65
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|66
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|67
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|68
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|69
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|70
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|71
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|72
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|73
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|74
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|75
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|76
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|77
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|78
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|79
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|80
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|81
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|82
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|83
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|84
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|85
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|86
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|87
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|88
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|89
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|90
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|91
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|92
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|93
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|94
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|95
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|96
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|97
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|98
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|99
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|100
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|101
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|102
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|103
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|104
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|105
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|106
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|107
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|108
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|109
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|110
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|111
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|112
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|113
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|114
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|115
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|116
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|117
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|118
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|119
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|120
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|121
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|122
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|123
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|124
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|125
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|126
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|127
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|128
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|129
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|130
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|131
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|132
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|133
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|134
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|135
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|136
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|137
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|138
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|139
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|140
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|141
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|142
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|143
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|144
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|145
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|146
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|147
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|148
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|149
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|150
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|151
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|152
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|153
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|154
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|155
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|156
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|157
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|158
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|159
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|160
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|161
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|162
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|163
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|164
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|165
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|166
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|167
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|168
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|169
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|170
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|171
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|172
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|173
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|174
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|175
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|176
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|177
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|178
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|179
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|180
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|181
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|182
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|183
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|184
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|185
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|186
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|187
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|188
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|189
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|190
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|191
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|192
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\scene.hlsl|193
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|1
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|2
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|3
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|4
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|5
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|6
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|7
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|8
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|9
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|10
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|11
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|12
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|13
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|14
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|15
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|16
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|17
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|18
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|19
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|20
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|21
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|22
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|23
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|24
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|25
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|26
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|27
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|28
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|29
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|30
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|31
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|32
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|33
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|34
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|35
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|36
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|37
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|38
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|39
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|40
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|41
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|42
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|43
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|44
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|45
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\shadow.hlsl|46
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|1
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|2
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|3
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|4
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|5
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|6
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|7
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|8
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|9
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|10
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|11
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|12
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|13
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|14
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|15
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|16
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|17
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|18
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|19
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|20
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|21
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|22
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|23
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|24
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|25
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|26
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|27
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|28
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|29
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|30
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|31
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|32
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|33
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|34
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|35
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|36
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|37
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|38
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|39
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|40
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|41
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|42
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|43
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|44
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|45
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|46
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|47
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|48
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|49
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|50
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|51
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|52
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|53
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|54
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|55
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|56
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|57
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|58
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|59
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|60
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|61
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|62
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|63
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|64
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|65
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|66
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|67
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|68
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|69
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|70
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|71
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|72
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|73
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|74
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|75
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|76
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|77
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|78
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|79
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|80
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|81
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|82
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|83
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|84
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|85
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|86
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|87
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|88
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|89
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|90
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|91
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|92
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|93
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|94
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|95
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|96
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|97
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|98
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|99
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|100
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|101
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|102
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|103
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|104
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|105
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|106
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|107
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|108
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|109
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|110
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|111
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|112
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|113
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|114
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|115
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|116
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|117
|
||||
E:\blu-flame.org\aquarium\src\intro\shaders\postprocessing.hlsl|118
|
||||
101
aquarium/src/intro/framework/codegen/shaders_shc.g.h
Normal file
101
aquarium/src/intro/framework/codegen/shaders_shc.g.h
Normal file
@@ -0,0 +1,101 @@
|
||||
#pragma once
|
||||
// WARNING: This file is autogenerated by shc. Do not edit
|
||||
|
||||
#pragma data_seg(".cs_5_0")
|
||||
static char cs_5_0[] = "cs_5_0";
|
||||
|
||||
#pragma data_seg(".vs_5_0")
|
||||
static char vs_5_0[] = "vs_5_0";
|
||||
|
||||
#pragma data_seg(".gs_5_0")
|
||||
static char gs_5_0[] = "gs_5_0";
|
||||
|
||||
#pragma data_seg(".ds_5_0")
|
||||
static char ds_5_0[] = "ds_5_0";
|
||||
|
||||
#pragma data_seg(".hs_5_0")
|
||||
static char hs_5_0[] = "hs_5_0";
|
||||
|
||||
#pragma data_seg(".ps_5_0")
|
||||
static char ps_5_0[] = "ps_5_0";
|
||||
|
||||
#pragma bss_seg(".shaderbss")
|
||||
static ID3D11ComputeShader* cs_Stone;
|
||||
static ID3D11ComputeShader* cs_Coral;
|
||||
static ID3D11ComputeShader* cs_Caustics;
|
||||
static ID3D11VertexShader* vs_Camera;
|
||||
static ID3D11GeometryShader* gs_Camera;
|
||||
static ID3D11VertexShader* vs_DrawHulls;
|
||||
static ID3D11GeometryShader* gs_DrawHulls;
|
||||
static ID3D11PixelShader* ps_DrawHulls;
|
||||
static ID3D11PixelShader* ps_DrawDepth;
|
||||
static ID3D11PixelShader* ps_BlurH;
|
||||
static ID3D11PixelShader* ps_BlurV;
|
||||
static ID3D11VertexShader* vs_ScreenQuad;
|
||||
static ID3D11PixelShader* ps_AmbientOcclussion;
|
||||
static ID3D11PixelShader* ps_PostProcess;
|
||||
static ID3D11PixelShader* ps_ToGamma;
|
||||
|
||||
#pragma data_seg(".CameraSODeclarations")
|
||||
extern D3D11_SO_DECLARATION_ENTRY CameraSODeclarations[6];
|
||||
|
||||
#pragma data_seg(".CameraStrides")
|
||||
extern UINT CameraStrides[2];
|
||||
|
||||
#pragma code_seg(".FrameworkShadersCompile")
|
||||
INLINE void FrameworkShadersCompile()
|
||||
{
|
||||
CompileShader("cs_Stone", cs_5_0);
|
||||
device->CreateComputeShader(shaderCode, shaderSize, NULL, &cs_Stone);
|
||||
CompileShader("cs_Coral", cs_5_0);
|
||||
device->CreateComputeShader(shaderCode, shaderSize, NULL, &cs_Coral);
|
||||
CompileShader("cs_Caustics", cs_5_0);
|
||||
device->CreateComputeShader(shaderCode, shaderSize, NULL, &cs_Caustics);
|
||||
CompileShader("Camera", vs_5_0);
|
||||
device->CreateVertexShader(shaderCode, shaderSize, NULL, &vs_Camera);
|
||||
device->CreateGeometryShaderWithStreamOutput(shaderCode, shaderSize, CameraSODeclarations, 6, CameraStrides, 2, D3D11_SO_NO_RASTERIZED_STREAM, NULL, &gs_Camera);
|
||||
CompileShader("vs_DrawHulls", vs_5_0);
|
||||
device->CreateVertexShader(shaderCode, shaderSize, NULL, &vs_DrawHulls);
|
||||
CompileShader("gs_DrawHulls", gs_5_0);
|
||||
device->CreateGeometryShader(shaderCode, shaderSize, NULL, &gs_DrawHulls);
|
||||
CompileShader("ps_DrawHulls", ps_5_0);
|
||||
device->CreatePixelShader(shaderCode, shaderSize, NULL, &ps_DrawHulls);
|
||||
CompileShader("ps_DrawDepth", ps_5_0);
|
||||
device->CreatePixelShader(shaderCode, shaderSize, NULL, &ps_DrawDepth);
|
||||
CompileShader("ps_BlurH", ps_5_0);
|
||||
device->CreatePixelShader(shaderCode, shaderSize, NULL, &ps_BlurH);
|
||||
CompileShader("ps_BlurV", ps_5_0);
|
||||
device->CreatePixelShader(shaderCode, shaderSize, NULL, &ps_BlurV);
|
||||
CompileShader("vs_ScreenQuad", vs_5_0);
|
||||
device->CreateVertexShader(shaderCode, shaderSize, NULL, &vs_ScreenQuad);
|
||||
CompileShader("ps_AmbientOcclussion", ps_5_0);
|
||||
device->CreatePixelShader(shaderCode, shaderSize, NULL, &ps_AmbientOcclussion);
|
||||
CompileShader("ps_PostProcess", ps_5_0);
|
||||
device->CreatePixelShader(shaderCode, shaderSize, NULL, &ps_PostProcess);
|
||||
CompileShader("ps_ToGamma", ps_5_0);
|
||||
device->CreatePixelShader(shaderCode, shaderSize, NULL, &ps_ToGamma);
|
||||
}
|
||||
|
||||
#ifndef AUTHORING
|
||||
#include "syncdata.g.h"
|
||||
#endif
|
||||
|
||||
struct SyncStruct_audio
|
||||
{
|
||||
float time;
|
||||
float cameraPos_x;
|
||||
float cameraPos_y;
|
||||
float cameraPos_z;
|
||||
float dummy1;
|
||||
float cameraAt_x;
|
||||
float cameraAt_y;
|
||||
float cameraAt_z;
|
||||
float dummy2;
|
||||
float cameraUp_x;
|
||||
float cameraUp_y;
|
||||
float cameraUp_z;
|
||||
};
|
||||
|
||||
#define SYNC
|
||||
#include "../sync.h"
|
||||
|
||||
12
aquarium/src/intro/framework/codegen/sync.g.meta
Normal file
12
aquarium/src/intro/framework/codegen/sync.g.meta
Normal file
@@ -0,0 +1,12 @@
|
||||
time
|
||||
cameraPos_x
|
||||
cameraPos_y
|
||||
cameraPos_z
|
||||
dummy1
|
||||
cameraAt_x
|
||||
cameraAt_y
|
||||
cameraAt_z
|
||||
dummy2
|
||||
cameraUp_x
|
||||
cameraUp_y
|
||||
cameraUp_z
|
||||
227
aquarium/src/intro/framework/codegen/syncdata.g.h
Normal file
227
aquarium/src/intro/framework/codegen/syncdata.g.h
Normal file
@@ -0,0 +1,227 @@
|
||||
#pragma once
|
||||
|
||||
#pragma data_seg(".syncDataAudio")
|
||||
static unsigned char syncDataAudio[] =
|
||||
{
|
||||
0x0C,
|
||||
0x0B,
|
||||
0x83,
|
||||
0xCC,
|
||||
0x3F,
|
||||
0x00,
|
||||
0x00,
|
||||
0xA0,
|
||||
0x40,
|
||||
0x82,
|
||||
0xD0,
|
||||
0x74,
|
||||
0xC2,
|
||||
0xEF,
|
||||
0xD2,
|
||||
0x04,
|
||||
0xC3,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x46,
|
||||
0x09,
|
||||
0x54,
|
||||
0x42,
|
||||
0x60,
|
||||
0xEC,
|
||||
0x87,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x80,
|
||||
0x3F,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x02,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0xC0,
|
||||
0x07,
|
||||
0x01,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0xF8,
|
||||
0x41,
|
||||
0x02,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x18,
|
||||
0x00,
|
||||
0x01,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0xC8,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0xA0,
|
||||
0x40,
|
||||
0x02,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0xC0,
|
||||
0x00,
|
||||
0x01,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x20,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0xA0,
|
||||
0xC2,
|
||||
0x08,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x17,
|
||||
0x00,
|
||||
0x18,
|
||||
0x00,
|
||||
0xC0,
|
||||
0x00,
|
||||
0xC1,
|
||||
0x00,
|
||||
0x00,
|
||||
0x01,
|
||||
0x01,
|
||||
0x01,
|
||||
0x40,
|
||||
0x01,
|
||||
0x01,
|
||||
0x00,
|
||||
0x03,
|
||||
0x00,
|
||||
0x01,
|
||||
0x00,
|
||||
0x01,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0xF0,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0x16,
|
||||
0xC3,
|
||||
0x00,
|
||||
0x00,
|
||||
0x16,
|
||||
0xC3,
|
||||
0x00,
|
||||
0x00,
|
||||
0x8C,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0x8C,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0x48,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0x48,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0x48,
|
||||
0x42,
|
||||
0x00,
|
||||
0x00,
|
||||
0x02,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0xC0,
|
||||
0x00,
|
||||
0x01,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0xC8,
|
||||
0x42,
|
||||
0x02,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x01,
|
||||
0x01,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x70,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0xA0,
|
||||
0xC2,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x01,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x01,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x80,
|
||||
0x3F,
|
||||
0x01,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00,
|
||||
0x00
|
||||
};
|
||||
|
||||
12
aquarium/src/intro/framework/codegen/syncvars.g.meta
Normal file
12
aquarium/src/intro/framework/codegen/syncvars.g.meta
Normal file
@@ -0,0 +1,12 @@
|
||||
time
|
||||
cameraPos_x
|
||||
cameraPos_y
|
||||
cameraPos_z
|
||||
dummy1
|
||||
cameraAt_x
|
||||
cameraAt_y
|
||||
cameraAt_z
|
||||
dummy2
|
||||
cameraUp_x
|
||||
cameraUp_y
|
||||
cameraUp_z
|
||||
12
aquarium/src/intro/framework/codegen/syncvars.meta
Normal file
12
aquarium/src/intro/framework/codegen/syncvars.meta
Normal file
@@ -0,0 +1,12 @@
|
||||
time
|
||||
cameraPos_x
|
||||
cameraPos_y
|
||||
cameraPos_z
|
||||
dummy1
|
||||
cameraAt_x
|
||||
cameraAt_y
|
||||
cameraAt_z
|
||||
dummy2
|
||||
cameraUp_x
|
||||
cameraUp_y
|
||||
cameraUp_z
|
||||
223
aquarium/src/intro/framework/directx.h
Normal file
223
aquarium/src/intro/framework/directx.h
Normal file
@@ -0,0 +1,223 @@
|
||||
#pragma once
|
||||
|
||||
#include <d3d11.h>
|
||||
|
||||
#define RES_MULTIPLIER 1
|
||||
#define DEPTH_STENCIL
|
||||
|
||||
#ifndef RELEASE
|
||||
#define D3D_DEVICE_FLAGS D3D11_CREATE_DEVICE_DEBUG
|
||||
#else
|
||||
#define D3D_DEVICE_FLAGS 0
|
||||
#endif
|
||||
|
||||
// types
|
||||
struct TEXTURE_2D_SRV_UAV_RTV
|
||||
{
|
||||
ID3D11Texture2D* TEX;
|
||||
ID3D11ShaderResourceView* SRV;
|
||||
ID3D11UnorderedAccessView* UAV;
|
||||
ID3D11RenderTargetView* RTV;
|
||||
ID3D11ShaderResourceView* SRVMips[12];
|
||||
ID3D11RenderTargetView* RTVMips[12];
|
||||
};
|
||||
|
||||
#pragma bss_seg(".directxBss")
|
||||
static ID3D11Device* device;
|
||||
static ID3D11DeviceContext* context;
|
||||
static IDXGISwapChain* swapChain;
|
||||
static ID3D11Texture2D* backBufferTexture;
|
||||
static ID3D11RenderTargetView* backBufferRTV;
|
||||
static ID3D11ShaderResourceView* backBufferSRV;
|
||||
|
||||
#ifdef DEPTH_STENCIL
|
||||
static ID3D11Texture2D* depthStencilBuffer;
|
||||
static ID3D11DepthStencilState* depthTestWrite;
|
||||
static ID3D11DepthStencilView* depthStencilView;
|
||||
#endif
|
||||
|
||||
#pragma data_seg(".backBufferRTVdesc")
|
||||
static D3D11_RENDER_TARGET_VIEW_DESC backBufferRTVdesc =
|
||||
{
|
||||
DXGI_FORMAT_B8G8R8A8_UNORM_SRGB,
|
||||
D3D11_RTV_DIMENSION_TEXTURE2D,
|
||||
{ 0 }
|
||||
};
|
||||
|
||||
#pragma data_seg(".backBufferSRVdesc")
|
||||
static D3D11_SHADER_RESOURCE_VIEW_DESC backBufferSRVdesc =
|
||||
{
|
||||
DXGI_FORMAT_B8G8R8A8_UNORM,
|
||||
D3D11_SRV_DIMENSION_TEXTURE2D,
|
||||
{ 0, 1 }
|
||||
};
|
||||
|
||||
|
||||
#pragma data_seg(".directxFeatureLevel")
|
||||
static D3D_FEATURE_LEVEL featureLevel[] = { D3D_FEATURE_LEVEL_11_0 };
|
||||
|
||||
#pragma data_seg(".directxSwapChainDesc")
|
||||
static DXGI_SWAP_CHAIN_DESC swapChainDesc =
|
||||
{
|
||||
{
|
||||
SCREENWIDTH,
|
||||
SCREENHEIGHT,
|
||||
{
|
||||
0, 1
|
||||
},
|
||||
DXGI_FORMAT_B8G8R8A8_UNORM,
|
||||
DXGI_MODE_SCANLINE_ORDER_UNSPECIFIED,
|
||||
DXGI_MODE_SCALING_UNSPECIFIED
|
||||
},
|
||||
{
|
||||
1, 0
|
||||
},
|
||||
DXGI_USAGE_RENDER_TARGET_OUTPUT | DXGI_USAGE_SHADER_INPUT,
|
||||
1,
|
||||
0,
|
||||
WINDOWED,
|
||||
DXGI_SWAP_EFFECT_DISCARD,
|
||||
0
|
||||
};
|
||||
|
||||
#pragma data_seg(".swapChainViewport")
|
||||
static D3D11_VIEWPORT swapChainViewport =
|
||||
{
|
||||
0.0f,
|
||||
0.0f,
|
||||
SCREENWIDTH,
|
||||
SCREENHEIGHT,
|
||||
0.0f,
|
||||
1.0f,
|
||||
};
|
||||
|
||||
#pragma data_seg(".standardTexDesc")
|
||||
static D3D11_TEXTURE2D_DESC standardTexDesc =
|
||||
{
|
||||
SCREENWIDTH, SCREENHEIGHT, 0, 1, DXGI_FORMAT_R16G16B16A16_FLOAT,
|
||||
{ 1, 0 }, D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_RENDER_TARGET | D3D11_BIND_SHADER_RESOURCE | D3D11_BIND_UNORDERED_ACCESS,
|
||||
0, D3D11_RESOURCE_MISC_GENERATE_MIPS
|
||||
};
|
||||
|
||||
#pragma data_seg(".rsvDesc")
|
||||
static UINT srvDesc[] =
|
||||
{
|
||||
0, 0, 0, 1
|
||||
};
|
||||
|
||||
#pragma data_seg(".rtvDesc")
|
||||
static UINT rtvDesc[] =
|
||||
{
|
||||
0, D3D11_RTV_DIMENSION_TEXTURE2DARRAY, 0, 0, 6
|
||||
};
|
||||
|
||||
#ifdef DEPTH_STENCIL
|
||||
|
||||
#pragma data_seg(".depthTestWriteStateDesc")
|
||||
static D3D11_DEPTH_STENCIL_DESC depthTestWriteStateDesc =
|
||||
{
|
||||
TRUE,
|
||||
D3D11_DEPTH_WRITE_MASK_ALL,
|
||||
D3D11_COMPARISON_LESS_EQUAL,
|
||||
FALSE,
|
||||
0,
|
||||
0,
|
||||
{},
|
||||
{}
|
||||
};
|
||||
|
||||
#pragma data_seg(".depthStencilViewDesc")
|
||||
static D3D11_DEPTH_STENCIL_VIEW_DESC depthStencilViewDesc =
|
||||
{
|
||||
DXGI_FORMAT_D32_FLOAT,
|
||||
D3D11_DSV_DIMENSION_TEXTURE2D,
|
||||
0,
|
||||
{
|
||||
0
|
||||
}
|
||||
};
|
||||
|
||||
#pragma data_seg(".depthBufferDesc")
|
||||
static D3D11_TEXTURE2D_DESC depthBufferDesc =
|
||||
{
|
||||
RES_MULTIPLIER * SCREENWIDTH,
|
||||
RES_MULTIPLIER * SCREENHEIGHT,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R32_TYPELESS,
|
||||
{
|
||||
1, 0
|
||||
},
|
||||
D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_DEPTH_STENCIL | D3D11_BIND_SHADER_RESOURCE,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#pragma code_seg("._createTextureSrvUavRtv")
|
||||
#if AUTHORING
|
||||
#include <map>
|
||||
static std::map<char*, TEXTURE_2D_SRV_UAV_RTV*> textureMap;
|
||||
|
||||
#define CreateTextureSrvRtv(textureName, width, height) _createTextureSrvUavRtv(#textureName, &textureName, width, height)
|
||||
#define CreateTextureSrvRtvDesc(textureName, width, height, desc) _createTextureSrvUavRtv(#textureName, &textureName, width, height, &desc)
|
||||
|
||||
void __stdcall _createTextureSrvUavRtv(char* texName, TEXTURE_2D_SRV_UAV_RTV* tex, int width, int height, D3D11_TEXTURE2D_DESC* desc = &standardTexDesc)
|
||||
{
|
||||
textureMap[texName] = tex;
|
||||
|
||||
#else
|
||||
|
||||
#define CreateTextureSrvRtv(textureName, width, height, desc, uav) _createTextureSrvUavRtv(&textureName, width, height)
|
||||
#define CreateTextureSrvRtvDesc(textureName, width, height, desc, uav) _createTextureSrvUavRtv(&textureName, width, height, &desc)
|
||||
|
||||
void __stdcall _createTextureSrvUavRtv(TEXTURE_2D_SRV_UAV_RTV* tex, int width, int height, D3D11_TEXTURE2D_DESC* desc = &standardTexDesc)
|
||||
{
|
||||
|
||||
#endif
|
||||
|
||||
desc->Width = width;
|
||||
desc->Height = height;
|
||||
CHECK(device->CreateTexture2D(desc, NULL, &tex->TEX)); // +14h
|
||||
CHECK(device->CreateShaderResourceView(tex->TEX, NULL, &tex->SRV)); // +1Ch
|
||||
CHECK(device->CreateRenderTargetView(tex->TEX, NULL, &tex->RTV)); // +24h
|
||||
if ((desc->BindFlags & D3D11_BIND_UNORDERED_ACCESS) != 0)
|
||||
{
|
||||
CHECK(device->CreateUnorderedAccessView(tex->TEX, NULL, &tex->UAV));
|
||||
}
|
||||
// explicit mip levels? create srvs and rtvs for each level
|
||||
for (UINT level = 0; level < desc->MipLevels; level++)
|
||||
{
|
||||
srvDesc[1] = D3D11_SRV_DIMENSION_TEXTURE2D;
|
||||
rtvDesc[1] = D3D11_RTV_DIMENSION_TEXTURE2D;
|
||||
if (desc->ArraySize == 6)
|
||||
{
|
||||
srvDesc[1] = D3D11_SRV_DIMENSION_TEXTURECUBE;
|
||||
rtvDesc[1] = D3D11_RTV_DIMENSION_TEXTURE2DARRAY;
|
||||
}
|
||||
srvDesc[2] = level;
|
||||
rtvDesc[2] = level;
|
||||
CHECK(device->CreateShaderResourceView(tex->TEX, (D3D11_SHADER_RESOURCE_VIEW_DESC*)srvDesc, &tex->SRVMips[level])); // +1Ch
|
||||
CHECK(device->CreateRenderTargetView(tex->TEX, (D3D11_RENDER_TARGET_VIEW_DESC*)rtvDesc, &tex->RTVMips[level])); // +24h
|
||||
}
|
||||
}
|
||||
|
||||
#pragma code_seg(".directxInit")
|
||||
INLINE void DirectXInit()
|
||||
{
|
||||
Log("DirectXInit");
|
||||
swapChainDesc.OutputWindow = windowHandle;
|
||||
CHECK(D3D11CreateDeviceAndSwapChain(NULL, D3D_DRIVER_TYPE_HARDWARE, NULL, D3D_DEVICE_FLAGS, featureLevel, 1, D3D11_SDK_VERSION, &swapChainDesc, &swapChain, &device, NULL, &context));
|
||||
CHECK(swapChain->GetBuffer(0, IID_ID3D11Texture2D, (LPVOID*)&backBufferTexture));
|
||||
CHECK(device->CreateRenderTargetView(backBufferTexture, &backBufferRTVdesc, &backBufferRTV));
|
||||
CHECK(device->CreateShaderResourceView(backBufferTexture, &backBufferSRVdesc, &backBufferSRV));
|
||||
|
||||
#ifdef DEPTH_STENCIL
|
||||
CHECK(device->CreateTexture2D(&depthBufferDesc, NULL, &depthStencilBuffer));
|
||||
CHECK(device->CreateDepthStencilState(&depthTestWriteStateDesc, &depthTestWrite));
|
||||
CHECK(device->CreateDepthStencilView(depthStencilBuffer, &depthStencilViewDesc, &depthStencilView));
|
||||
#endif
|
||||
}
|
||||
141
aquarium/src/intro/framework/framework.h
Normal file
141
aquarium/src/intro/framework/framework.h
Normal file
@@ -0,0 +1,141 @@
|
||||
#pragma once
|
||||
|
||||
#ifndef _DEBUG
|
||||
#define INLINE __forceinline
|
||||
#else
|
||||
#define INLINE
|
||||
#endif
|
||||
|
||||
#define VC_EXTRALEAN
|
||||
#define WIN32_LEAN_AND_MEAN
|
||||
#include <Windows.h>
|
||||
#include "log.h"
|
||||
#include "window.h"
|
||||
#include "directx.h"
|
||||
#include "synth/4klang.h"
|
||||
#include "sound.h"
|
||||
#include "video.h"
|
||||
|
||||
#pragma bss_seg(".shadersbss")
|
||||
static void* shaderCode;
|
||||
static size_t shaderSize;
|
||||
|
||||
#ifdef AUTHORING
|
||||
bool CompileShader_Authoring(char* entryPoint, char* profile);
|
||||
#define CompileShader(entryPoint, profile) { if (!CompileShader_Authoring(entryPoint, profile)) { shadersOK = false; return; } }
|
||||
#else
|
||||
void CompileShader_Release(char* entryPoint, char* profile);
|
||||
#define CompileShader(entryPoint, profile) CompileShader_Release(entryPoint, profile)
|
||||
#endif
|
||||
|
||||
#pragma code_seg(".introforward")
|
||||
void IntroInit();
|
||||
void IntroUpdate(float _introPosition);
|
||||
|
||||
#ifdef AUTHORING
|
||||
#include "authoring.h"
|
||||
#endif
|
||||
|
||||
#include "codegen/shaders_shc.g.h"
|
||||
|
||||
#include "shaders.h"
|
||||
|
||||
INLINE void FrameworkInit()
|
||||
{
|
||||
Log("FrameworkInit");
|
||||
WindowInit();
|
||||
DirectXInit();
|
||||
|
||||
#ifdef SYNC
|
||||
SyncInit();
|
||||
#endif
|
||||
|
||||
#ifdef AUTHORING
|
||||
AuthoringInit();
|
||||
#endif
|
||||
|
||||
ShadersInit();
|
||||
FrameworkShadersCompile();
|
||||
SoundInit();
|
||||
IntroInit();
|
||||
|
||||
#ifdef VIDEO
|
||||
VideoInit();
|
||||
#endif
|
||||
}
|
||||
|
||||
INLINE float FrameworkGetIntroPosition()
|
||||
{
|
||||
#ifdef AUTHORING
|
||||
return AuthoringGetIntroPosition();
|
||||
#elif VIDEO
|
||||
return VideoGetPosition();
|
||||
#else
|
||||
return SoundGetIntroPosition();
|
||||
#endif
|
||||
}
|
||||
|
||||
INLINE void FrameworkUpdate()
|
||||
{
|
||||
#ifdef AUTHORING
|
||||
if (::WaitForSingleObject(shaderCompileEvent, 0) == WAIT_OBJECT_0)
|
||||
{
|
||||
::Sleep(100);
|
||||
shadersOK = true;
|
||||
FrameworkShadersCompile();
|
||||
}
|
||||
|
||||
if (!shadersOK)
|
||||
{
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef VIDEO
|
||||
float t = VideoGetPosition();
|
||||
#else
|
||||
float t = FrameworkGetIntroPosition();
|
||||
#endif
|
||||
|
||||
#ifdef SYNC
|
||||
SyncUpdate(t);
|
||||
#endif
|
||||
|
||||
#ifdef AUTHORING
|
||||
IntroUpdate(t);
|
||||
AuthoringUpdate();
|
||||
#else
|
||||
IntroUpdate(t);
|
||||
#endif
|
||||
|
||||
#ifdef VIDEO
|
||||
VideoUpdate();
|
||||
#endif
|
||||
}
|
||||
|
||||
INLINE void FrameworkDispose()
|
||||
{
|
||||
Log("FrameworkDispose");
|
||||
#ifdef AUTHORING
|
||||
SoundDone();
|
||||
AuthoringDispose();
|
||||
#endif
|
||||
|
||||
#ifdef VIDEO
|
||||
VideoDispose();
|
||||
#endif
|
||||
}
|
||||
|
||||
static const float introLength = (float)MAX_SAMPLES / (float)(SAMPLES_PER_TICK * SOUND_TICKS_PER_SCENE);
|
||||
|
||||
INLINE bool FrameworkContinueExecuting()
|
||||
{
|
||||
#ifndef AUTHORING
|
||||
if (FrameworkGetIntroPosition() >= introLength)
|
||||
return false;
|
||||
|
||||
return !GetAsyncKeyState(VK_ESCAPE);
|
||||
#else
|
||||
return SharedMemoryTool->KeepAlive;
|
||||
#endif
|
||||
}
|
||||
65
aquarium/src/intro/framework/log.h
Normal file
65
aquarium/src/intro/framework/log.h
Normal file
@@ -0,0 +1,65 @@
|
||||
#pragma once
|
||||
|
||||
#ifdef _DEBUG
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
|
||||
void Log(char* _text, ...)
|
||||
{
|
||||
va_list args;
|
||||
va_start(args, _text);
|
||||
vprintf(_text, args);
|
||||
va_end(args);
|
||||
|
||||
printf("\n");
|
||||
}
|
||||
|
||||
void Warn(char* _text)
|
||||
{
|
||||
HANDLE hstdout = GetStdHandle(STD_OUTPUT_HANDLE);
|
||||
|
||||
CONSOLE_SCREEN_BUFFER_INFO csbi;
|
||||
GetConsoleScreenBufferInfo(hstdout, &csbi);
|
||||
|
||||
SetConsoleTextAttribute(hstdout, FOREGROUND_RED | FOREGROUND_GREEN | FOREGROUND_INTENSITY);
|
||||
OutputDebugString("WARNING: ");
|
||||
OutputDebugString(_text);
|
||||
OutputDebugString("\n");
|
||||
Log(_text);
|
||||
|
||||
SetConsoleTextAttribute(hstdout, csbi.wAttributes);
|
||||
}
|
||||
|
||||
void Error(char* _text)
|
||||
{
|
||||
HANDLE hstdout = GetStdHandle(STD_OUTPUT_HANDLE);
|
||||
|
||||
CONSOLE_SCREEN_BUFFER_INFO csbi;
|
||||
GetConsoleScreenBufferInfo(hstdout, &csbi);
|
||||
|
||||
SetConsoleTextAttribute(hstdout, FOREGROUND_RED | FOREGROUND_INTENSITY);
|
||||
OutputDebugString("ERROR: ");
|
||||
OutputDebugString(_text);
|
||||
OutputDebugString("\n");
|
||||
Log(_text);
|
||||
SetConsoleTextAttribute(hstdout, csbi.wAttributes);
|
||||
}
|
||||
|
||||
void CHECK(HRESULT _hResult)
|
||||
{
|
||||
if (_hResult != S_OK)
|
||||
{
|
||||
HLOCAL pBuffer;
|
||||
FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, NULL, _hResult, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPSTR)&pBuffer, 512, NULL);
|
||||
Error((char*)pBuffer);
|
||||
DebugBreak();
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
#define Log(text)
|
||||
#define Warn(text)
|
||||
#define Error(text)
|
||||
#define CHECK(hresult) hresult
|
||||
#endif
|
||||
139
aquarium/src/intro/framework/shaders.h
Normal file
139
aquarium/src/intro/framework/shaders.h
Normal file
@@ -0,0 +1,139 @@
|
||||
#pragma once
|
||||
|
||||
#include <d3dcompiler.h>
|
||||
|
||||
#pragma bss_seg(".shadersbss")
|
||||
static ID3DBlob* shaderBlob;
|
||||
static ID3DBlob* errorBlob;
|
||||
static pD3DCompile d3dCompile;
|
||||
|
||||
#pragma data_seg(".d3dcompiler")
|
||||
static char d3dcompiler[] = "d3dcompiler_47.dll";
|
||||
|
||||
#pragma data_seg(".minifiedShader")
|
||||
#include "codegen\intro_hlsl.g.h"
|
||||
|
||||
#ifdef AUTHORING
|
||||
|
||||
#include <process.h>
|
||||
#include <io.h>
|
||||
#include <stdio.h>
|
||||
|
||||
static char g_sMonitoredShaderPath[MAX_PATH];
|
||||
static __time64_t shaderChangedDate;
|
||||
|
||||
DWORD WINAPI filemon(void* args)
|
||||
{
|
||||
while (true)
|
||||
{
|
||||
_finddata_t fdata;
|
||||
long hfile = _findfirst(g_sMonitoredShaderPath, &fdata);
|
||||
if (hfile != -1)
|
||||
{
|
||||
if (fdata.time_write != shaderChangedDate)
|
||||
{
|
||||
shaderChangedDate = fdata.time_write;
|
||||
::SetEvent(shaderCompileEvent);
|
||||
}
|
||||
_findclose(hfile);
|
||||
}
|
||||
::Sleep(100);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
INLINE void ShadersInit()
|
||||
{
|
||||
HINSTANCE hl = LoadLibrary(d3dcompiler);
|
||||
if (!hl)
|
||||
{
|
||||
d3dcompiler[13] = '3';
|
||||
hl = LoadLibrary(d3dcompiler);
|
||||
}
|
||||
d3dCompile = (pD3DCompile)GetProcAddress(hl, "D3DCompile");
|
||||
|
||||
#ifdef AUTHORING
|
||||
static char exePath[MAX_PATH];
|
||||
GetModuleFileName(NULL, exePath, MAX_PATH);
|
||||
PathRemoveFileSpec(exePath);
|
||||
PathCombine(g_sMonitoredShaderPath, exePath, "..\\src\\intro\\framework\\codegen\\merged.hlsl");
|
||||
|
||||
_finddata_t fdata;
|
||||
long hfile = _findfirst(g_sMonitoredShaderPath, &fdata);
|
||||
if (hfile != -1)
|
||||
{
|
||||
shaderChangedDate = fdata.time_write;
|
||||
_findclose(hfile);
|
||||
}
|
||||
|
||||
shaderCompileEvent = ::CreateEvent(NULL, FALSE, FALSE, TEXT("WriteEvent"));
|
||||
SetThreadPriority((HANDLE)CreateThread(0, 0, &filemon, 0, 0, 0), THREAD_PRIORITY_BELOW_NORMAL);
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef AUTHORING
|
||||
#pragma code_seg(".CompileShaderA")
|
||||
bool CompileShader_Authoring(char* entryPoint, char* profile)
|
||||
{
|
||||
ReadFile((char*)g_sMonitoredShaderPath, (char**)&shaderCode, &shaderSize);
|
||||
d3dCompile(shaderCode, shaderSize, g_sMonitoredShaderPath, NULL, NULL, entryPoint, profile, D3DCOMPILE_SKIP_VALIDATION | D3DCOMPILE_SKIP_OPTIMIZATION | D3DCOMPILE_DEBUG | D3DCOMPILE_OPTIMIZATION_LEVEL0, 0, &shaderBlob, &errorBlob);
|
||||
if (errorBlob != NULL)
|
||||
{
|
||||
auto error = (char*)errorBlob->GetBufferPointer();
|
||||
if (shaderBlob != NULL)
|
||||
{
|
||||
Warn(error);
|
||||
}
|
||||
else
|
||||
{
|
||||
Error(error);
|
||||
}
|
||||
|
||||
DWORD cbSize = strlen(error);
|
||||
DWORD cbWritten = 0;
|
||||
|
||||
WriteFile(
|
||||
hShaderErrorPipe, // pipe handle
|
||||
&cbSize, // message
|
||||
sizeof(DWORD), // message length
|
||||
&cbWritten, // bytes written
|
||||
NULL); // not overlapped
|
||||
|
||||
WriteFile(
|
||||
hShaderErrorPipe, // pipe handle
|
||||
error, // message
|
||||
cbSize, // message length
|
||||
&cbWritten, // bytes written
|
||||
NULL); // not overlapped
|
||||
|
||||
if (shaderBlob == NULL)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
shaderSize = shaderBlob->GetBufferSize();
|
||||
shaderCode = shaderBlob->GetBufferPointer();
|
||||
return true;
|
||||
};
|
||||
#endif
|
||||
|
||||
#pragma code_seg(".CompileShaderR")
|
||||
void CompileShader_Release(char* entryPoint, char* profile)
|
||||
{
|
||||
#ifdef _DEBUG
|
||||
d3dCompile(merged_hlsl, sizeof(merged_hlsl), NULL, NULL, NULL, entryPoint, profile, 0, 0, &shaderBlob, &errorBlob);
|
||||
if (errorBlob != NULL)
|
||||
{
|
||||
auto error = errorBlob->GetBufferPointer();
|
||||
Error((char*)error);
|
||||
}
|
||||
#else
|
||||
d3dCompile(merged_hlsl, sizeof(merged_hlsl), NULL, NULL, NULL, entryPoint, profile, 0, 0, &shaderBlob, 0);
|
||||
#endif
|
||||
|
||||
shaderSize = shaderBlob->GetBufferSize();
|
||||
shaderCode = shaderBlob->GetBufferPointer();
|
||||
};
|
||||
6
aquarium/src/intro/framework/shaders/fullscreen.hlsl
Normal file
6
aquarium/src/intro/framework/shaders/fullscreen.hlsl
Normal file
@@ -0,0 +1,6 @@
|
||||
void main(uint i : SV_VertexID, out sample float2 uv : TEXCOORD, out float4 p : SV_Position)
|
||||
{
|
||||
uv = float2(i / 2, i % 2);
|
||||
p = float4(uv * 2 - 1, 0, 1);
|
||||
uv.y = 1 - uv.y;
|
||||
}
|
||||
15
aquarium/src/intro/framework/shaders/histogramGather.hlsl
Normal file
15
aquarium/src/intro/framework/shaders/histogramGather.hlsl
Normal file
@@ -0,0 +1,15 @@
|
||||
Texture2DMS<float4,1> in0 : register(t0);
|
||||
RWTexture1D<uint> histogramBucketR : register(u1);
|
||||
RWTexture1D<uint> histogramBucketG : register(u2);
|
||||
RWTexture1D<uint> histogramBucketB : register(u3);
|
||||
RWTexture1D<float4> histogramOut : register(u4);
|
||||
|
||||
[numthreads(16, 16, 1)]
|
||||
void main(uint3 id : SV_DispatchThreadID)
|
||||
{
|
||||
int3 iPixel = in0[id.xy].rgb * 255.0f;
|
||||
|
||||
InterlockedAdd(histogramBucketR[iPixel.r], 1);
|
||||
InterlockedAdd(histogramBucketG[iPixel.g], 1);
|
||||
InterlockedAdd(histogramBucketB[iPixel.b], 1);
|
||||
}
|
||||
12
aquarium/src/intro/framework/shaders/histogramMaximum.hlsl
Normal file
12
aquarium/src/intro/framework/shaders/histogramMaximum.hlsl
Normal file
@@ -0,0 +1,12 @@
|
||||
RWTexture1D<uint> histogramBucketR : register(u1);
|
||||
RWTexture1D<uint> histogramBucketG : register(u2);
|
||||
RWTexture1D<uint> histogramBucketB : register(u3);
|
||||
RWTexture1D<float4> histogramOut : register(u4);
|
||||
|
||||
[numthreads(16, 1, 1)]
|
||||
void main(uint3 id : SV_DispatchThreadID)
|
||||
{
|
||||
InterlockedMax(histogramBucketR[256], histogramBucketR[id.x]);
|
||||
InterlockedMax(histogramBucketG[256], histogramBucketG[id.x]);
|
||||
InterlockedMax(histogramBucketB[256], histogramBucketB[id.x]);
|
||||
}
|
||||
28
aquarium/src/intro/framework/shaders/histogramSpread.hlsl
Normal file
28
aquarium/src/intro/framework/shaders/histogramSpread.hlsl
Normal file
@@ -0,0 +1,28 @@
|
||||
RWTexture1D<uint> histogramBucketR : register(u1);
|
||||
RWTexture1D<uint> histogramBucketG : register(u2);
|
||||
RWTexture1D<uint> histogramBucketB : register(u3);
|
||||
RWTexture2D<uint4> histogramOut : register(u4);
|
||||
|
||||
[numthreads(16, 16, 1)]
|
||||
void main(uint3 id : SV_DispatchThreadID)
|
||||
{
|
||||
float3 hist = float3(
|
||||
log(1.0 + histogramBucketR[id.x]) / log(1.0 + histogramBucketR[256]),
|
||||
log(1.0 + histogramBucketG[id.x]) / log(1.0 + histogramBucketG[256]),
|
||||
log(1.0 + histogramBucketB[id.x]) / log(1.0 + histogramBucketB[256]));
|
||||
|
||||
int x = id.x;
|
||||
uint yB = (uint)(255 * (1.0f - hist.b));
|
||||
uint yG = (uint)(255 * (1.0f - hist.g));
|
||||
uint yR = (uint)(255 * (1.0f - hist.r));
|
||||
|
||||
float4 color = max(0, float4(128 * step(yB, id.y), 128 * step(yG, id.y), 128 * step(yR, id.y), 0));
|
||||
if (id.y == yB)
|
||||
color.r = 255;
|
||||
if (id.y == yG)
|
||||
color.g = 255;
|
||||
if (id.y == yR)
|
||||
color.b = 255;
|
||||
|
||||
histogramOut[id.xy] = color;
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
Texture2DMS<float4,1> in0 : register(t0);
|
||||
RWTexture2D<uint> paradeBucketR : register(u1);
|
||||
RWTexture2D<uint> paradeBucketG : register(u2);
|
||||
RWTexture2D<uint> paradeBucketB : register(u3);
|
||||
RWTexture2D<uint> paradeBucketA : register(u4);
|
||||
RWTexture2D<uint> vectorScopeBucket : register(u5);
|
||||
RWTexture2D<uint4> paradeOut : register(u6);
|
||||
RWTexture2D<uint4> vectorScopeOut : register(u7);
|
||||
|
||||
[numthreads(16, 16, 1)]
|
||||
void main(uint3 id : SV_DispatchThreadID)
|
||||
{
|
||||
float3 pixel = in0[id.xy].rgb;
|
||||
int3 iPixel = pixel * 255.0f;
|
||||
float luminance = dot(pixel, float3(0.2126f, 0.7152f, 0.0722f));
|
||||
float2 f = float2(0.492f, 0.877f) * (pixel.br - luminance);
|
||||
int2 uv = min(255, max(0, 128 * (1 + f / float2(0.436f, 0.615f))));
|
||||
|
||||
float3 resolution;
|
||||
in0.GetDimensions(resolution.x, resolution.y, resolution.z);
|
||||
int paradeCoord = (id.x * 255.0f) / resolution.x;
|
||||
|
||||
InterlockedAdd(paradeBucketR[int2(paradeCoord, 255 - iPixel.r)], 1);
|
||||
InterlockedAdd(paradeBucketG[int2(paradeCoord, 255 - iPixel.g)], 1);
|
||||
InterlockedAdd(paradeBucketB[int2(paradeCoord, 255 - iPixel.b)], 1);
|
||||
InterlockedAdd(paradeBucketA[int2(paradeCoord, 255 - (uint)(255.0f * luminance))], 1);
|
||||
InterlockedAdd(vectorScopeBucket[uv], 1);
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
RWTexture2D<uint> paradeBucketR : register(u1);
|
||||
RWTexture2D<uint> paradeBucketG : register(u2);
|
||||
RWTexture2D<uint> paradeBucketB : register(u3);
|
||||
RWTexture2D<uint> paradeBucketA : register(u4);
|
||||
RWTexture2D<uint> vectorScopeBucket : register(u5);
|
||||
RWTexture2D<uint4> paradeOut : register(u6);
|
||||
RWTexture2D<uint4> vectorScopeOut : register(u7);
|
||||
|
||||
[numthreads(16, 16, 1)]
|
||||
void main(uint3 id : SV_DispatchThreadID)
|
||||
{
|
||||
InterlockedMax(paradeBucketR[uint2(256, 0)], paradeBucketR[id.xy]);
|
||||
InterlockedMax(paradeBucketG[uint2(256, 0)], paradeBucketG[id.xy]);
|
||||
InterlockedMax(paradeBucketB[uint2(256, 0)], paradeBucketB[id.xy]);
|
||||
InterlockedMax(paradeBucketA[uint2(256, 0)], paradeBucketA[id.xy]);
|
||||
InterlockedMax(vectorScopeBucket[uint2(256, 0)], vectorScopeBucket[id.xy]);
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
RWTexture2D<uint> paradeBucketR : register(u1);
|
||||
RWTexture2D<uint> paradeBucketG : register(u2);
|
||||
RWTexture2D<uint> paradeBucketB : register(u3);
|
||||
RWTexture2D<uint> paradeBucketA : register(u4);
|
||||
RWTexture2D<uint> vectorScopeBucket : register(u5);
|
||||
RWTexture2D<uint4> paradeOut : register(u6);
|
||||
RWTexture2D<uint4> vectorScopeOut : register(u7);
|
||||
|
||||
[numthreads(16, 16, 1)]
|
||||
void main( uint3 id : SV_DispatchThreadID )
|
||||
{
|
||||
uint4 parade = uint4(
|
||||
255.0f * log(1.0f + paradeBucketR[id.xy]) / log(1.0f + paradeBucketR[uint2(256, 0)]),
|
||||
255.0f * log(1.0f + paradeBucketG[id.xy]) / log(1.0f + paradeBucketG[uint2(256, 0)]),
|
||||
255.0f * log(1.0f + paradeBucketB[id.xy]) / log(1.0f + paradeBucketB[uint2(256, 0)]),
|
||||
255.0f * log(1.0f + paradeBucketA[id.xy]) / log(1.0f + paradeBucketA[uint2(256, 0)]));
|
||||
paradeOut[id.xy + uint2(0 * 256, 0)] = parade.w;
|
||||
paradeOut[id.xy + uint2(3 * 256, 0)] = parade.z * float4(1, 0, 0, 1);
|
||||
paradeOut[id.xy + uint2(2 * 256, 0)] = parade.y * float4(0, 1, 0, 1);
|
||||
paradeOut[id.xy + uint2(1 * 256, 0)] = parade.x * float4(0, 0, 1, 1);
|
||||
|
||||
float luminance = 1.0f - max(0.0f, min(1.0f, log(1.0f + vectorScopeBucket[id.xy]) / log(1.0f + vectorScopeBucket[uint2(256, 0)])));
|
||||
float2 f = (id.xy - 128.0f) / 128.0f;
|
||||
if (length(f) > 1)
|
||||
luminance = 0.0f;
|
||||
|
||||
float2 uv = ((id.xy / 128.0f) - 1.0f) * float2(0.436f, 0.615f);
|
||||
|
||||
float3 _a = float3(0, -0.3950f, 2.03252f);
|
||||
float3 _b = float3(1.14025f, -0.581f, 0);
|
||||
uint3 rgb = luminance * 255.0f * min(1, max(0, (0.5f + uv.x * _a + uv.y * _b)));
|
||||
|
||||
vectorScopeOut[id.xy] = uint4(rgb.zyx, 255);
|
||||
}
|
||||
8
aquarium/src/intro/framework/shaders/resolve.hlsl
Normal file
8
aquarium/src/intro/framework/shaders/resolve.hlsl
Normal file
@@ -0,0 +1,8 @@
|
||||
Texture2D<float4> t2d0 : register(t0);
|
||||
SamplerState s0 : register(s0);
|
||||
|
||||
float4 main(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
return t2d0.SampleLevel(s0, uv, 0).rgba;
|
||||
}
|
||||
|
||||
11
aquarium/src/intro/framework/shaders/textureViewer.hlsl
Normal file
11
aquarium/src/intro/framework/shaders/textureViewer.hlsl
Normal file
@@ -0,0 +1,11 @@
|
||||
Texture2D<float4> in0 : register(t0);
|
||||
RWTexture2D<uint4> o0 : register(u1);
|
||||
RWTexture2D<uint4> o1 : register(u2);
|
||||
|
||||
[numthreads(16, 16, 1)]
|
||||
void main(uint3 id : SV_DispatchThreadID)
|
||||
{
|
||||
float4 i = in0[id.xy];
|
||||
o0[id.xy] = float4(i.bgra) * 255;
|
||||
o1[id.xy] = float4(i.a, i.a, i.a, 1) * 255;
|
||||
}
|
||||
88
aquarium/src/intro/framework/sound.h
Normal file
88
aquarium/src/intro/framework/sound.h
Normal file
@@ -0,0 +1,88 @@
|
||||
#pragma once
|
||||
|
||||
#pragma data_seg(".wavehdr")
|
||||
#define SOUND_TICKS_PER_SCENE 64
|
||||
|
||||
#include <mmsystem.h>
|
||||
#include <mmreg.h>
|
||||
|
||||
#pragma bss_seg(".audio_bss")
|
||||
#ifdef AUTHORING
|
||||
static HANDLE SoundThread;
|
||||
static float* soundBuffer;
|
||||
#else
|
||||
static float soundBuffer[MAX_SAMPLES * 2];
|
||||
#endif
|
||||
static HWAVEOUT hWaveOut;
|
||||
|
||||
#pragma data_seg(".wavehdr")
|
||||
#ifndef RELEASE
|
||||
WAVEHDR WaveHDR =
|
||||
{
|
||||
(LPSTR)soundBuffer,
|
||||
MAX_SAMPLES * sizeof(float) * 2,
|
||||
0, 0, 0, 0, 0, 0
|
||||
};
|
||||
#else
|
||||
WAVEHDR WaveHDR =
|
||||
{
|
||||
(LPSTR)soundBuffer,
|
||||
MAX_SAMPLES * sizeof(float) * 2,
|
||||
0, 0, WHDR_PREPARED, 0, 0, 0
|
||||
};
|
||||
#endif
|
||||
|
||||
#pragma data_seg(".wavefmt")
|
||||
WAVEFORMATEX WaveFMT =
|
||||
{
|
||||
#ifdef FLOAT_32BIT
|
||||
WAVE_FORMAT_IEEE_FLOAT,
|
||||
#else
|
||||
WAVE_FORMAT_PCM,
|
||||
#endif
|
||||
2, // channels
|
||||
SAMPLE_RATE, // samples per sec
|
||||
SAMPLE_RATE * sizeof(float) * 2, // bytes per sec
|
||||
sizeof(float) * 2, // block alignment;
|
||||
sizeof(float) * 8, // bits per sample
|
||||
0 // extension not needed
|
||||
};
|
||||
|
||||
#pragma data_seg(".mmtime")
|
||||
static MMTIME mmtime =
|
||||
{
|
||||
TIME_SAMPLES
|
||||
};
|
||||
|
||||
INLINE float SoundGetIntroPosition()
|
||||
{
|
||||
waveOutGetPosition(hWaveOut, &mmtime, sizeof(MMTIME));
|
||||
return mmtime.u.sample / (float)(SAMPLES_PER_TICK * SOUND_TICKS_PER_SCENE);
|
||||
}
|
||||
|
||||
#pragma code_seg(".initsnd")
|
||||
INLINE void SoundInit()
|
||||
{
|
||||
#ifdef AUTHORING
|
||||
SoundThread =
|
||||
#endif
|
||||
CreateThread(0, 0, (LPTHREAD_START_ROUTINE)_4klang_render, soundBuffer, 0, 0);
|
||||
|
||||
#ifndef VIDEO
|
||||
::Sleep(1024);// give the 4klang render call some time
|
||||
|
||||
waveOutOpen(&hWaveOut, -1, &WaveFMT, 0, 0, 0);
|
||||
#ifndef RELEASE
|
||||
waveOutPrepareHeader(hWaveOut, &WaveHDR, 0x20);
|
||||
#endif
|
||||
waveOutWrite(hWaveOut, &WaveHDR, 0x20);
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef AUTHORING
|
||||
INLINE void SoundDone()
|
||||
{
|
||||
waveOutClose(hWaveOut);
|
||||
TerminateThread(SoundThread, 0);
|
||||
}
|
||||
#endif
|
||||
90
aquarium/src/intro/framework/sync.h
Normal file
90
aquarium/src/intro/framework/sync.h
Normal file
@@ -0,0 +1,90 @@
|
||||
#pragma once
|
||||
|
||||
#pragma bss_seg(".syncbss")
|
||||
static ID3D11Buffer* SyncBuffer;
|
||||
static SyncStruct_audio* Sync;
|
||||
|
||||
#pragma data_seg(".syncBufferDesc")
|
||||
static D3D11_BUFFER_DESC syncBufferDesc =
|
||||
{
|
||||
sizeof(SyncStruct_audio),
|
||||
D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_CONSTANT_BUFFER,
|
||||
0,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
#pragma code_seg(".SyncInit")
|
||||
INLINE void SyncInit()
|
||||
{
|
||||
device->CreateBuffer(&syncBufferDesc, nullptr, &SyncBuffer);
|
||||
Sync = (SyncStruct_audio*)(syncDataAudio + 1);
|
||||
}
|
||||
|
||||
#pragma code_seg(".SyncUpdate")
|
||||
INLINE void SyncUpdate(float t)
|
||||
{
|
||||
auto fRow = (t * SOUND_TICKS_PER_SCENE);
|
||||
auto iChannelCount = syncDataAudio[0];
|
||||
auto pTarget = (float*)&syncDataAudio[1];
|
||||
auto pChannels = (char*)(pTarget + iChannelCount);
|
||||
for (int iChannel = 0; iChannel < iChannelCount; ++iChannel)
|
||||
{
|
||||
auto iValueCount = *(unsigned short*)(pChannels);
|
||||
auto pChannelRows = (unsigned short*)(pChannels + 2);
|
||||
auto pChannelModes = (char*)(pChannelRows + iValueCount);
|
||||
auto pChannelValues = (float*)(pChannelModes + iValueCount);
|
||||
pChannels = (char*)(pChannelValues + iValueCount);
|
||||
for (int iIndex = 0; iIndex < iValueCount;)
|
||||
{
|
||||
int iRow = pChannelRows[iIndex];
|
||||
int iNextRow = pChannelRows[iIndex + 1];
|
||||
if (iRow <= fRow && iNextRow + 1 > fRow)
|
||||
{
|
||||
float t = (fRow - iRow) / (iNextRow - iRow + 1);
|
||||
switch (pChannelModes[iIndex])
|
||||
{
|
||||
case 0: // Step
|
||||
t = 0.0f;
|
||||
break;
|
||||
case 1: // Linear
|
||||
break;
|
||||
case 2: // Cubic
|
||||
t *= t * (3 - 2 * t);
|
||||
break;
|
||||
case 3: // EaseIn
|
||||
t *= t;
|
||||
break;
|
||||
case 4: // EaseOut
|
||||
t *= -t + 2;
|
||||
break;
|
||||
}
|
||||
pTarget[iChannel] = (1 - t) * pChannelValues[iIndex] + t * pChannelValues[iIndex + 1];
|
||||
break;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (pChannelModes[iIndex] != 0)
|
||||
++iIndex;
|
||||
|
||||
pTarget[iChannel] = pChannelValues[iIndex];
|
||||
|
||||
++iIndex;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef AUTHORING
|
||||
Sync = (SyncStruct_audio*)pTarget;
|
||||
if (SyncBuffer != NULL)
|
||||
SyncBuffer->Release();
|
||||
|
||||
syncBufferDesc.ByteWidth = iChannelCount * sizeof(float);
|
||||
device->CreateBuffer(&syncBufferDesc, nullptr, &SyncBuffer);
|
||||
|
||||
if (iChannelCount != 0)
|
||||
#endif
|
||||
|
||||
context->UpdateSubresource(SyncBuffer, 0, NULL, pTarget, iChannelCount * sizeof(float), sizeof(float));
|
||||
}
|
||||
1626
aquarium/src/intro/framework/synth/4klang.asm
Normal file
1626
aquarium/src/intro/framework/synth/4klang.asm
Normal file
File diff suppressed because it is too large
Load Diff
22
aquarium/src/intro/framework/synth/4klang.h
Normal file
22
aquarium/src/intro/framework/synth/4klang.h
Normal file
@@ -0,0 +1,22 @@
|
||||
// some useful song defines for 4klang
|
||||
#define SAMPLE_RATE 44100
|
||||
#define BPM 150.000000
|
||||
#define MAX_INSTRUMENTS 26
|
||||
#define MAX_PATTERNS 124
|
||||
#define PATTERN_SIZE_SHIFT 4
|
||||
#define PATTERN_SIZE (1 << PATTERN_SIZE_SHIFT)
|
||||
#define MAX_TICKS (MAX_PATTERNS*PATTERN_SIZE)
|
||||
#define SAMPLES_PER_TICK 4410
|
||||
#define MAX_SAMPLES (SAMPLES_PER_TICK*MAX_TICKS)
|
||||
#define POLYPHONY 1
|
||||
#define FLOAT_32BIT
|
||||
#define SAMPLE_TYPE float
|
||||
|
||||
#define WINDOWS_OBJECT
|
||||
|
||||
// declaration of the external synth render function, you'll always need that
|
||||
extern "C" void __stdcall _4klang_render(void*);
|
||||
// declaration of the external envelope buffer. access only if you're song was exported with that option
|
||||
extern "C" float _4klang_envelope_buffer;
|
||||
// declaration of the external note buffer. access only if you're song was exported with that option
|
||||
extern "C" int _4klang_note_buffer;
|
||||
1969
aquarium/src/intro/framework/synth/4klang.inc
Normal file
1969
aquarium/src/intro/framework/synth/4klang.inc
Normal file
File diff suppressed because it is too large
Load Diff
BIN
aquarium/src/intro/framework/synth/8klang.merge
Normal file
BIN
aquarium/src/intro/framework/synth/8klang.merge
Normal file
Binary file not shown.
2000
aquarium/src/intro/framework/synth/patterns.dbg
Normal file
2000
aquarium/src/intro/framework/synth/patterns.dbg
Normal file
File diff suppressed because it is too large
Load Diff
152
aquarium/src/intro/framework/video.h
Normal file
152
aquarium/src/intro/framework/video.h
Normal file
@@ -0,0 +1,152 @@
|
||||
#ifdef VIDEO
|
||||
#include <vfw.h>
|
||||
|
||||
#define FPS 60
|
||||
#define MOTION_BLUR 8
|
||||
|
||||
typedef struct
|
||||
{
|
||||
PAVISTREAM m_ps;
|
||||
PAVISTREAM m_psCompressed;
|
||||
PAVISTREAM m_psAudio;
|
||||
AVISTREAMINFO m_strhdr;
|
||||
AVICOMPRESSOPTIONS m_opts;
|
||||
PAVIFILE m_pfile;
|
||||
BITMAPINFOHEADER m_alpbi;
|
||||
} AVIWRITER;
|
||||
|
||||
static D3D11_TEXTURE2D_DESC videoStagingTextureDesc =
|
||||
{
|
||||
SCREENWIDTH,
|
||||
SCREENHEIGHT,
|
||||
1,
|
||||
1,
|
||||
DXGI_FORMAT_R8G8B8A8_UNORM,
|
||||
{ 1, 0 },
|
||||
D3D11_USAGE_STAGING,
|
||||
0,
|
||||
D3D11_CPU_ACCESS_READ,
|
||||
0
|
||||
};
|
||||
|
||||
#pragma bss_seg(".videobss")
|
||||
static AVIWRITER avi;
|
||||
static int frame = 0;
|
||||
static ID3D11Texture2D* videoStagingTexture;
|
||||
static byte buffer[3 * SCREENWIDTH * SCREENHEIGHT];
|
||||
static int tempBuffer[3 * SCREENWIDTH * SCREENHEIGHT];
|
||||
|
||||
#pragma code_seg(".VideoInit")
|
||||
void VideoInit()
|
||||
{
|
||||
AVIFileInit();
|
||||
CHECK(AVIFileOpen(&avi.m_pfile, "intro.avi", OF_WRITE | OF_CREATE, NULL));
|
||||
|
||||
memset(&avi.m_strhdr, 0, sizeof(avi.m_strhdr));
|
||||
avi.m_strhdr.fccType = streamtypeVIDEO;
|
||||
avi.m_strhdr.fccHandler = 0;
|
||||
avi.m_strhdr.dwScale = 1;
|
||||
avi.m_strhdr.dwRate = FPS;
|
||||
avi.m_strhdr.dwSuggestedBufferSize = 0;// 3 * SCREENWIDTH * SCREENHEIGHT;
|
||||
SetRect(&avi.m_strhdr.rcFrame, 0, 0, SCREENWIDTH, SCREENHEIGHT);
|
||||
|
||||
CHECK(AVIFileCreateStream(avi.m_pfile, &avi.m_ps, &avi.m_strhdr));
|
||||
|
||||
memset(&avi.m_strhdr, 0, sizeof(avi.m_strhdr));
|
||||
avi.m_strhdr.fccType = streamtypeAUDIO;
|
||||
avi.m_strhdr.dwScale = WaveFMT.nBlockAlign;
|
||||
avi.m_strhdr.dwRate = WaveFMT.nSamplesPerSec * WaveFMT.nBlockAlign;
|
||||
avi.m_strhdr.dwSampleSize = WaveFMT.nBlockAlign;
|
||||
avi.m_strhdr.dwQuality = (DWORD)-1;
|
||||
SetRect(&avi.m_strhdr.rcFrame, 0, 0, SCREENWIDTH, SCREENHEIGHT);
|
||||
|
||||
CHECK(AVIFileCreateStream(avi.m_pfile, &avi.m_psAudio, &avi.m_strhdr));
|
||||
CHECK(AVIStreamSetFormat(avi.m_psAudio, 0, &WaveFMT, sizeof(WAVEFORMATEX)));
|
||||
|
||||
auto ops = &avi.m_opts;
|
||||
if (AVISaveOptions(windowHandle, 0, 1, &avi.m_ps, &ops) == FALSE)
|
||||
{
|
||||
ExitProcess(0);
|
||||
}
|
||||
|
||||
CHECK(AVIMakeCompressedStream(&avi.m_psCompressed, avi.m_ps, &avi.m_opts, NULL));
|
||||
|
||||
memset(&avi.m_alpbi, 0, sizeof(avi.m_alpbi));
|
||||
avi.m_alpbi.biSize = sizeof(avi.m_alpbi);
|
||||
avi.m_alpbi.biWidth = SCREENWIDTH;
|
||||
avi.m_alpbi.biHeight = SCREENHEIGHT;
|
||||
avi.m_alpbi.biPlanes = 1;
|
||||
avi.m_alpbi.biBitCount = 24;
|
||||
avi.m_alpbi.biCompression = BI_RGB;
|
||||
|
||||
CHECK(AVIStreamSetFormat(avi.m_psCompressed, 0, &avi.m_alpbi, sizeof(avi.m_alpbi)));
|
||||
|
||||
CHECK(device->CreateTexture2D(&videoStagingTextureDesc, NULL, &videoStagingTexture));
|
||||
}
|
||||
|
||||
#pragma code_seg(".VideoGetPosition")
|
||||
float VideoGetPosition()
|
||||
{
|
||||
float seconds = (float)frame / (float)(FPS * MOTION_BLUR);
|
||||
float samples = seconds * SAMPLE_RATE;
|
||||
float ticks = samples / (float)SAMPLES_PER_TICK;
|
||||
return ticks / SOUND_TICKS_PER_SCENE;
|
||||
}
|
||||
|
||||
#pragma code_seg(".VideoUpdate")
|
||||
void VideoUpdate()
|
||||
{
|
||||
static D3D11_MAPPED_SUBRESOURCE videoMappedSubresource;
|
||||
|
||||
context->CopyResource(videoStagingTexture, backBufferTexture);
|
||||
context->Map(videoStagingTexture, 0, D3D11_MAP_READ, 0, &videoMappedSubresource);
|
||||
|
||||
auto introPtr = (byte*)videoMappedSubresource.pData;
|
||||
for (int y = 0; y < SCREENHEIGHT; ++y)
|
||||
{
|
||||
auto vy = SCREENHEIGHT - y - 1;
|
||||
for (int x = 0; x < SCREENWIDTH; ++x)
|
||||
{
|
||||
for (int c = 0; c < 4; ++c)
|
||||
{
|
||||
byte color = *introPtr++;
|
||||
if (c < 3)
|
||||
{
|
||||
auto vc = 2 - c;
|
||||
auto vidx = vc + 3 * (x + SCREENWIDTH * vy);
|
||||
tempBuffer[vidx] += color;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
context->Unmap(videoStagingTexture, 0);
|
||||
|
||||
if ((frame++ % MOTION_BLUR) == 0)
|
||||
{
|
||||
auto videoPtr = (byte*)buffer;
|
||||
auto tempPtr = (int*)tempBuffer;
|
||||
for (int i = 0; i < SCREENWIDTH * SCREENHEIGHT * 3; ++i)
|
||||
{
|
||||
*videoPtr++ = (byte)(*tempPtr / MOTION_BLUR);
|
||||
*tempPtr++ = 0;
|
||||
}
|
||||
|
||||
CHECK(AVIStreamWrite(avi.m_psCompressed, (frame - 1) / MOTION_BLUR, 1, buffer, 3 * SCREENWIDTH * SCREENHEIGHT, AVIIF_KEYFRAME, NULL, NULL));
|
||||
}
|
||||
}
|
||||
|
||||
#pragma code_seg(".VideoDispose")
|
||||
void VideoDispose()
|
||||
{
|
||||
auto const extraSamples = 0;// SOUND_TICKS_PER_SCENE * SAMPLES_PER_TICK / 4;
|
||||
static SAMPLE_TYPE audioBuffer[2 * (MAX_SAMPLES + extraSamples)];
|
||||
memcpy(audioBuffer + extraSamples * 2, WaveHDR.lpData, WaveHDR.dwBufferLength);
|
||||
AVIStreamWrite(avi.m_psAudio, 0, MAX_SAMPLES + extraSamples, audioBuffer, WaveHDR.dwBufferLength + extraSamples * sizeof(SAMPLE_TYPE) * 2, 0, NULL, NULL);
|
||||
|
||||
AVIStreamClose(avi.m_ps);
|
||||
AVIStreamClose(avi.m_psCompressed);
|
||||
AVIStreamClose(avi.m_psAudio);
|
||||
AVIFileClose(avi.m_pfile);
|
||||
AVIFileExit();
|
||||
}
|
||||
#endif
|
||||
93
aquarium/src/intro/framework/window.h
Normal file
93
aquarium/src/intro/framework/window.h
Normal file
@@ -0,0 +1,93 @@
|
||||
#pragma once
|
||||
|
||||
#ifndef SCREENWIDTH
|
||||
#define SCREENWIDTH 1280
|
||||
#endif
|
||||
|
||||
#ifndef SCREENHEIGHT
|
||||
#define SCREENHEIGHT 720
|
||||
#endif
|
||||
|
||||
#ifndef ASPECT
|
||||
#define ASPECT 1.6f
|
||||
#endif
|
||||
|
||||
#ifndef WINDOWED
|
||||
#define WINDOWED TRUE
|
||||
#endif
|
||||
|
||||
#pragma bss_seg(".windowbss")
|
||||
static float windowWidth = SCREENWIDTH;
|
||||
static float windowHeight = SCREENHEIGHT;
|
||||
static HWND windowHandle;
|
||||
|
||||
#ifdef VIDEO
|
||||
#define windowTitle "Intro (rendering to video)"
|
||||
#endif
|
||||
|
||||
#ifdef RELEASE
|
||||
#define windowTitle "Intro (release)"
|
||||
#endif
|
||||
|
||||
#ifdef SHADERDEBUG
|
||||
#define windowTitle "Intro (shader debug)"
|
||||
#endif
|
||||
|
||||
#ifdef AUTHORING
|
||||
#define windowTitle "Intro (authoring)"
|
||||
#undef WINDOWED
|
||||
#define WINDOWED TRUE
|
||||
#endif
|
||||
|
||||
#ifndef windowTitle
|
||||
#define windowTitle "Intro (unknown configuration)"
|
||||
#endif
|
||||
|
||||
#pragma code_seg(".windowInit")
|
||||
INLINE void WindowInit()
|
||||
{
|
||||
Log("WindowInit");
|
||||
#ifdef RELEASE
|
||||
#if WINDOWED == TRUE
|
||||
windowHandle = CreateWindowExA(0, (LPCSTR)0x0000C019, 0, WS_POPUP | WS_VISIBLE, 0, 0, SCREENWIDTH, SCREENHEIGHT, 0, 0, 0, 0);
|
||||
#else
|
||||
windowHandle = CreateWindowExA(0, (LPCSTR)0x0000C019, 0, WS_OVERLAPPEDWINDOW | WS_VISIBLE | WS_MAXIMIZE, 0, 0, 0, 0, 0, 0, 0, 0);
|
||||
#endif
|
||||
ShowCursor(false);
|
||||
#else
|
||||
WNDCLASSEX wndclass;
|
||||
wndclass.cbSize = sizeof(wndclass);
|
||||
wndclass.style = CS_HREDRAW | CS_VREDRAW | CS_OWNDC;
|
||||
wndclass.lpfnWndProc = (WNDPROC)DefWindowProc;
|
||||
wndclass.cbClsExtra = 0;
|
||||
wndclass.cbWndExtra = 0;
|
||||
wndclass.hInstance = NULL;
|
||||
wndclass.hIcon = LoadIcon(NULL, IDI_APPLICATION);
|
||||
wndclass.hCursor = LoadCursor(NULL, IDC_ARROW);
|
||||
wndclass.hbrBackground = (HBRUSH)GetStockObject(BLACK_BRUSH);
|
||||
wndclass.lpszMenuName = NULL;
|
||||
wndclass.lpszClassName = "IntroWindowClass";
|
||||
wndclass.hIconSm = LoadIcon(NULL, IDI_APPLICATION);
|
||||
|
||||
RegisterClassEx(&wndclass);
|
||||
#ifndef AUTHORING
|
||||
windowHandle = CreateWindowExA(0,
|
||||
wndclass.lpszClassName,
|
||||
windowTitle,
|
||||
WS_EX_APPWINDOW,
|
||||
GetSystemMetrics(SM_CXSCREEN) - windowWidth - 16,
|
||||
0,
|
||||
windowWidth + 16,
|
||||
windowHeight + 39,
|
||||
NULL,
|
||||
NULL,
|
||||
GetModuleHandle(NULL),
|
||||
NULL
|
||||
);
|
||||
ShowWindow(windowHandle, SW_NORMAL);
|
||||
SetWindowPos(windowHandle, 0, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE);
|
||||
#else
|
||||
windowHandle = CreateWindowExA(0, wndclass.lpszClassName, windowTitle, 0, 0, 0, SCREENWIDTH, SCREENHEIGHT, 0, 0, GetModuleHandle(NULL), 0);
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
586
aquarium/src/intro/intro.vcxproj
Normal file
586
aquarium/src/intro/intro.vcxproj
Normal file
@@ -0,0 +1,586 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Authoring|Win32">
|
||||
<Configuration>Authoring</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="ShaderDebug|Win32">
|
||||
<Configuration>ShaderDebug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Compress|Win32">
|
||||
<Configuration>Compress</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Video|Win32">
|
||||
<Configuration>Video</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{EC001821-5569-4BB5-87B3-20CB8FF9137B}</ProjectGuid>
|
||||
<Keyword>Win32Proj</Keyword>
|
||||
<RootNamespace>ConsoleApplication1</RootNamespace>
|
||||
<ProjectName>aquarium</ProjectName>
|
||||
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v143</PlatformToolset>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Video|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v143</PlatformToolset>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<PlatformToolset>v143</PlatformToolset>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v143</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<PlatformToolset>v143</PlatformToolset>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>NotSet</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Video|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)'=='Authoring|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" 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 Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)bin\</OutDir>
|
||||
<IntDir>$(SolutionDir)obj\$(Configuration)\</IntDir>
|
||||
<TargetName>$(ProjectName)_$(Configuration)</TargetName>
|
||||
<ExecutablePath>$(SolutionDir)\tools;$(ExecutablePath)</ExecutablePath>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)bin\</OutDir>
|
||||
<IntDir>$(SolutionDir)obj\$(Configuration)\</IntDir>
|
||||
<TargetName>$(ProjectName)_$(Configuration)</TargetName>
|
||||
<ExecutablePath>$(SolutionDir)\tools;$(ExecutablePath)</ExecutablePath>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)bin\</OutDir>
|
||||
<IntDir>$(SolutionDir)obj\$(Configuration)\</IntDir>
|
||||
<TargetName>$(ProjectName)_$(Configuration)</TargetName>
|
||||
<ExecutablePath>$(SolutionDir)\tools;$(ExecutablePath)</ExecutablePath>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)bin\</OutDir>
|
||||
<IntDir>$(SolutionDir)obj\$(Configuration)\</IntDir>
|
||||
<TargetName>$(ProjectName)_$(Configuration)</TargetName>
|
||||
<ExecutablePath>$(SolutionDir)\tools;$(ExecutablePath)</ExecutablePath>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
<OutDir>$(SolutionDir)bin\</OutDir>
|
||||
<IntDir>$(SolutionDir)obj\$(Configuration)\</IntDir>
|
||||
<TargetName>$(ProjectName)_$(Configuration)</TargetName>
|
||||
<ExecutablePath>$(SolutionDir)\tools;$(ExecutablePath)</ExecutablePath>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>SHADERDEBUG;WIN32;_DEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<CallingConvention>StdCall</CallingConvention>
|
||||
<StructMemberAlignment>Default</StructMemberAlignment>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<AdditionalDependencies>dxgi.lib;d3d11.lib;D3dcompiler.lib;winmm.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>
|
||||
</Command>
|
||||
</PreBuildEvent>
|
||||
<CustomBuildStep>
|
||||
<Command>
|
||||
</Command>
|
||||
</CustomBuildStep>
|
||||
<CustomBuildStep>
|
||||
<Message>
|
||||
</Message>
|
||||
<Outputs>
|
||||
</Outputs>
|
||||
<Inputs>
|
||||
</Inputs>
|
||||
</CustomBuildStep>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>VIDEO;WIN32;SYNC_PLAYER;_DEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<CallingConvention>StdCall</CallingConvention>
|
||||
<StructMemberAlignment>Default</StructMemberAlignment>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<AdditionalDependencies>dxgi.lib;d3d11.lib;D3dcompiler.lib;winmm.lib;vfw32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>
|
||||
</Command>
|
||||
</PreBuildEvent>
|
||||
<CustomBuildStep>
|
||||
<Command>
|
||||
</Command>
|
||||
</CustomBuildStep>
|
||||
<CustomBuildStep>
|
||||
<Message>
|
||||
</Message>
|
||||
<Outputs>
|
||||
</Outputs>
|
||||
<Inputs>
|
||||
</Inputs>
|
||||
</CustomBuildStep>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">
|
||||
<ClCompile>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<PreprocessorDefinitions>AUTHORING;WIN32;_DEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<CallingConvention>StdCall</CallingConvention>
|
||||
<StructMemberAlignment>Default</StructMemberAlignment>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<AdditionalDependencies>dxgi.lib;d3d11.lib;dxguid.lib;D3dcompiler.lib;winmm.lib;Shlwapi.lib;ws2_32.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>
|
||||
</Command>
|
||||
</PreBuildEvent>
|
||||
<CustomBuildStep>
|
||||
<Command>
|
||||
</Command>
|
||||
</CustomBuildStep>
|
||||
<CustomBuildStep>
|
||||
<Message>
|
||||
</Message>
|
||||
<Outputs>
|
||||
</Outputs>
|
||||
<Inputs>
|
||||
</Inputs>
|
||||
</CustomBuildStep>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MinSpace</Optimization>
|
||||
<FunctionLevelLinking>false</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>COMPRESS;RELEASE;WIN32;NDEBUG;SYNC_PLAYER;_CONSOLE;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<DebugInformationFormat Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">None</DebugInformationFormat>
|
||||
<FavorSizeOrSpeed Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Size</FavorSizeOrSpeed>
|
||||
<OmitFramePointers Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</OmitFramePointers>
|
||||
<WholeProgramOptimization Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</WholeProgramOptimization>
|
||||
<ExceptionHandling Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</ExceptionHandling>
|
||||
<RuntimeLibrary Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">MultiThreadedDLL</RuntimeLibrary>
|
||||
<BufferSecurityCheck Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</BufferSecurityCheck>
|
||||
<FloatingPointModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Fast</FloatingPointModel>
|
||||
<DebugInformationFormat>None</DebugInformationFormat>
|
||||
<FavorSizeOrSpeed>Size</FavorSizeOrSpeed>
|
||||
<OmitFramePointers>true</OmitFramePointers>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<ExceptionHandling>false</ExceptionHandling>
|
||||
<BufferSecurityCheck>false</BufferSecurityCheck>
|
||||
<AdditionalOptions>/QIfist %(AdditionalOptions)</AdditionalOptions>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<CallingConvention>StdCall</CallingConvention>
|
||||
<StructMemberAlignment>Default</StructMemberAlignment>
|
||||
<EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<GenerateDebugInformation>false</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<AdditionalDependencies>dxgi.lib;dxguid.lib;d3d11.lib;D3dcompiler.lib;winmm.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<EntryPointSymbol>main</EntryPointSymbol>
|
||||
<AdditionalOptions>/CRINKLER /TRANSFORM:CALLS /COMPMODE:SLOW /HASHTRIES:100 /HASHSIZE:256 /ORDERTRIES:2000 /UNSAFEIMPORT /REPORT:crinkler.html /PROGRESSGUI %(AdditionalOptions)</AdditionalOptions>
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>
|
||||
</Command>
|
||||
</PreBuildEvent>
|
||||
<CustomBuildStep>
|
||||
<Command>
|
||||
</Command>
|
||||
</CustomBuildStep>
|
||||
<CustomBuildStep>
|
||||
<Message>
|
||||
</Message>
|
||||
<Outputs>
|
||||
</Outputs>
|
||||
<Inputs>
|
||||
</Inputs>
|
||||
</CustomBuildStep>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<PrecompiledHeader>
|
||||
</PrecompiledHeader>
|
||||
<Optimization>MinSpace</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<PreprocessorDefinitions>RELEASE;WIN32;SYNC_PLAYER;_DEBUG;_CONSOLE;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AssemblerOutput>All</AssemblerOutput>
|
||||
<CallingConvention>StdCall</CallingConvention>
|
||||
<FloatingPointModel>Fast</FloatingPointModel>
|
||||
<StructMemberAlignment>Default</StructMemberAlignment>
|
||||
<FavorSizeOrSpeed>Size</FavorSizeOrSpeed>
|
||||
<WholeProgramOptimization>false</WholeProgramOptimization>
|
||||
<EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<SubSystem>Console</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<AdditionalDependencies>dxgi.lib;d3d11.lib;dxguid.lib;D3dcompiler.lib;winmm.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<LinkTimeCodeGeneration>Default</LinkTimeCodeGeneration>
|
||||
</Link>
|
||||
<PreBuildEvent>
|
||||
<Command>
|
||||
</Command>
|
||||
</PreBuildEvent>
|
||||
<CustomBuildStep>
|
||||
<Command>
|
||||
</Command>
|
||||
</CustomBuildStep>
|
||||
<CustomBuildStep>
|
||||
<Message>
|
||||
</Message>
|
||||
<Outputs>
|
||||
</Outputs>
|
||||
<Inputs>
|
||||
</Inputs>
|
||||
</CustomBuildStep>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="main.cpp">
|
||||
<AssemblerOutput Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">All</AssemblerOutput>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">false</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">false</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">false</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">false</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="framework\authoring.h" />
|
||||
<ClInclude Include="framework\directx.h" />
|
||||
<ClInclude Include="framework\framework.h" />
|
||||
<ClInclude Include="framework\log.h" />
|
||||
<ClInclude Include="framework\shaders.h" />
|
||||
<ClInclude Include="framework\sync.h" />
|
||||
<ClInclude Include="framework\codegen\syncdata.g.h" />
|
||||
<ClInclude Include="framework\synth\4klang.h" />
|
||||
<ClInclude Include="framework\video.h" />
|
||||
<ClInclude Include="framework\window.h" />
|
||||
<ClInclude Include="intro\data.h" />
|
||||
<ClInclude Include="framework\sound.h" />
|
||||
<ClInclude Include="intro\update.h" />
|
||||
<ClInclude Include="intro\functions.h" />
|
||||
<ClInclude Include="intro\init.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<CustomBuild Include="framework\synth\4klang.asm">
|
||||
<FileType>Document</FileType>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">yasm -f win32 -o "$(IntermediateOutputPath)framework\synth\4klang.obj" "$(ProjectDir)framework\synth\4klang.asm"</Command>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Compiling 4klang...</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">$(IntermediateOutputPath)framework\synth\4klang.obj</Outputs>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">$(ProjectDir)framework\synth\4klang.inc</AdditionalInputs>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">yasm -f win32 -o "$(IntermediateOutputPath)framework\synth\4klang.obj" "$(ProjectDir)framework\synth\4klang.asm"</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">yasm -f win32 -o "$(IntermediateOutputPath)framework\synth\4klang.obj" "$(ProjectDir)framework\synth\4klang.asm"</Command>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Compiling 4klang...</Message>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compiling 4klang...</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">$(IntermediateOutputPath)framework\synth\4klang.obj</Outputs>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntermediateOutputPath)framework\synth\4klang.obj</Outputs>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">$(ProjectDir)framework\synth\4klang.inc</AdditionalInputs>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)framework\synth\4klang.inc</AdditionalInputs>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">yasm -f win32 -o "$(IntermediateOutputPath)framework\synth\4klang.obj" "$(ProjectDir)framework\synth\4klang.asm"</Command>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Compiling 4klang...</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">$(IntermediateOutputPath)framework\synth\4klang.obj</Outputs>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">$(ProjectDir)framework\synth\4klang.inc</AdditionalInputs>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">yasm -D AUTHORING -f win32 -o "$(IntermediateOutputPath)framework\synth\4klang.obj" "$(ProjectDir)framework\synth\4klang.asm" -g cv8</Command>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Compiling 4klang...</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">$(IntermediateOutputPath)framework\synth\4klang.obj</Outputs>
|
||||
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">$(ProjectDir)framework\synth\4klang.inc</AdditionalInputs>
|
||||
</CustomBuild>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="framework\synth\4klang.inc" />
|
||||
<None Include="framework\synth\8klang.merge" />
|
||||
<None Include="framework\synth\patterns.dbg" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<CustomBuild Include="shaders\intro.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">$(TargetDir)shc "%(FullPath)" "$(ProjectDir)framework\codegen\intro_hlsl.g.h" "$(ProjectDir)framework\codegen\shaders_shc.g.h" "$(ProjectDir)framework\codegen\merged.hlsl" "$(ProjectDir)framework\codegen\syncvars.meta"</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(TargetDir)shc "%(FullPath)" "$(ProjectDir)framework\codegen\intro_hlsl.g.h" "$(ProjectDir)framework\codegen\shaders_shc.g.h" "$(ProjectDir)framework\codegen\merged.hlsl" "$(ProjectDir)framework\codegen\syncvars.meta"</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">$(TargetDir)shc "%(FullPath)" "$(ProjectDir)framework\codegen\intro_hlsl.g.h" "$(ProjectDir)framework\codegen\shaders_shc.g.h" "$(ProjectDir)framework\codegen\merged.hlsl" "$(ProjectDir)framework\codegen\syncvars.meta"</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">$(TargetDir)shc "%(FullPath)" "$(ProjectDir)framework\codegen\intro_hlsl.g.h" "$(ProjectDir)framework\codegen\shaders_shc.g.h" "$(ProjectDir)framework\codegen\merged.hlsl" "$(ProjectDir)framework\codegen\syncvars.meta"</Command>
|
||||
<Command Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">$(TargetDir)shc "%(FullPath)" "$(ProjectDir)framework\codegen\intro_hlsl.g.h" "$(ProjectDir)framework\codegen\shaders_shc.g.h" "$(ProjectDir)framework\codegen\merged.hlsl" "$(ProjectDir)framework\codegen\syncvars.meta"</Command>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Compiling intro.hlsl...</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">$(ProjectDir)framework\codegen\shaders_shc.g.h;$(ProjectDir)framework\codegen\intro_hlsl.g.h;$(ProjectDir)framework\codegen\merged.hlsl;$(ProjectDir)framework\codegen\syncvars.meta;%(Outputs)</Outputs>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compiling intro.hlsl...</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)framework\codegen\shaders_shc.g.h;$(ProjectDir)framework\codegen\intro_hlsl.g.h;$(ProjectDir)framework\codegen\merged.hlsl;$(ProjectDir)framework\codegen\syncvars.meta;%(Outputs)</Outputs>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Compiling intro.hlsl...</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">$(ProjectDir)framework\codegen\shaders_shc.g.h;$(ProjectDir)framework\codegen\intro_hlsl.g.h;$(ProjectDir)framework\codegen\merged.hlsl;$(ProjectDir)framework\codegen\syncvars.meta;%(Outputs)</Outputs>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Compiling intro.hlsl...</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">$(ProjectDir)framework\codegen\shaders_shc.g.h;$(ProjectDir)framework\codegen\intro_hlsl.g.h;$(ProjectDir)framework\codegen\merged.hlsl;$(ProjectDir)framework\codegen\syncvars.meta;%(Outputs)</Outputs>
|
||||
<Message Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Compiling intro.hlsl...</Message>
|
||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">$(ProjectDir)framework\codegen\shaders_shc.g.h;$(ProjectDir)framework\codegen\intro_hlsl.g.h;$(ProjectDir)framework\codegen\merged.hlsl;$(ProjectDir)framework\codegen\syncvars.meta;%(Outputs)</Outputs>
|
||||
</CustomBuild>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<FxCompile Include="framework\shaders\fullscreen.hlsl">
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Vertex</ShaderType>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Vertex</ShaderType>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Vertex</ShaderType>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Vertex</ShaderType>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Vertex</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">5.0</ShaderModel>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">5.0</ShaderModel>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">5.0</ShaderModel>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">5.0</ShaderModel>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">5.0</ShaderModel>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</EnableDebuggingInformation>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</EnableDebuggingInformation>
|
||||
</FxCompile>
|
||||
<FxCompile Include="framework\shaders\histogramGather.hlsl">
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">5.0</ShaderModel>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</EnableDebuggingInformation>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</EnableDebuggingInformation>
|
||||
</FxCompile>
|
||||
<FxCompile Include="framework\shaders\histogramSpread.hlsl">
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">5.0</ShaderModel>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</EnableDebuggingInformation>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</EnableDebuggingInformation>
|
||||
</FxCompile>
|
||||
<FxCompile Include="framework\shaders\histogramMaximum.hlsl">
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">5.0</ShaderModel>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</EnableDebuggingInformation>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</EnableDebuggingInformation>
|
||||
</FxCompile>
|
||||
<FxCompile Include="framework\shaders\paradeVectorscopeGather.hlsl">
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">5.0</ShaderModel>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</EnableDebuggingInformation>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</EnableDebuggingInformation>
|
||||
</FxCompile>
|
||||
<FxCompile Include="framework\shaders\paradeVectorscopeMaximum.hlsl">
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">5.0</ShaderModel>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</EnableDebuggingInformation>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</EnableDebuggingInformation>
|
||||
</FxCompile>
|
||||
<FxCompile Include="framework\shaders\paradeVectorscopeSpread.hlsl">
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">5.0</ShaderModel>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</EnableDebuggingInformation>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</EnableDebuggingInformation>
|
||||
</FxCompile>
|
||||
<FxCompile Include="framework\shaders\resolve.hlsl">
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Pixel</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Pixel</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Pixel</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Pixel</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Pixel</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">5.0</ShaderModel>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</EnableDebuggingInformation>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</EnableDebuggingInformation>
|
||||
</FxCompile>
|
||||
<FxCompile Include="framework\shaders\textureViewer.hlsl">
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">5.0</ShaderModel>
|
||||
<ShaderType Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">Compute</ShaderType>
|
||||
<ShaderModel Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">5.0</ShaderModel>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</EnableDebuggingInformation>
|
||||
<DisableOptimizations Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</DisableOptimizations>
|
||||
<EnableDebuggingInformation Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</EnableDebuggingInformation>
|
||||
</FxCompile>
|
||||
<FxCompile Include="shaders\camera.hlsl">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</ExcludedFromBuild>
|
||||
</FxCompile>
|
||||
<FxCompile Include="shaders\functions.hlsl">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</ExcludedFromBuild>
|
||||
</FxCompile>
|
||||
<FxCompile Include="shaders\postprocessing.hlsl">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</ExcludedFromBuild>
|
||||
</FxCompile>
|
||||
<FxCompile Include="shaders\scene.hlsl">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</ExcludedFromBuild>
|
||||
</FxCompile>
|
||||
<FxCompile Include="shaders\shadow.hlsl">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</ExcludedFromBuild>
|
||||
</FxCompile>
|
||||
<FxCompile Include="shaders\textures.hlsl">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='ShaderDebug|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Video|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Authoring|Win32'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Compress|Win32'">true</ExcludedFromBuild>
|
||||
</FxCompile>
|
||||
<None Include="shaders\structs.hlsl">
|
||||
<FileType>Document</FileType>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Xml Include="intro\sync.xml" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
6
aquarium/src/intro/intro.vcxproj.user
Normal file
6
aquarium/src/intro/intro.vcxproj.user
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<ShowAllFiles>true</ShowAllFiles>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
151
aquarium/src/intro/intro/data.h
Normal file
151
aquarium/src/intro/intro/data.h
Normal file
@@ -0,0 +1,151 @@
|
||||
#pragma once
|
||||
|
||||
#define SHADOW_RES 512
|
||||
|
||||
struct STexture
|
||||
{
|
||||
ID3D11Texture2D* TEX;
|
||||
ID3D11ShaderResourceView* SRV;
|
||||
ID3D11RenderTargetView* RTV;
|
||||
ID3D11UnorderedAccessView* UAV;
|
||||
};
|
||||
|
||||
#pragma bss_seg(".introbss")
|
||||
static ID3D11Buffer* camBuffer;
|
||||
static ID3D11UnorderedAccessView* camUav;
|
||||
static ID3D11Buffer* cameraBuffer;
|
||||
static ID3D11Buffer* lightBuffer;
|
||||
static ID3D11Buffer* constantBufferTemp[2];
|
||||
static ID3D11SamplerState* samplerState;
|
||||
static ID3D11DepthStencilView* shadowDepthStencilView;
|
||||
static ID3D11ShaderResourceView* depthBufferSrv;
|
||||
static STexture tex1;
|
||||
static STexture tex2;
|
||||
static STexture mrt1;
|
||||
static STexture mrt2;
|
||||
static STexture mrt3;
|
||||
static STexture rt;
|
||||
static STexture ao;
|
||||
static STexture shadow1;
|
||||
static STexture shadow2;
|
||||
static STexture shadow3;
|
||||
static char zero[32];
|
||||
static FLOAT one[] = {1, 1, 1, 1};
|
||||
static ID3D11RenderTargetView* rtvs[3];
|
||||
|
||||
#pragma data_seg(".samplerDesc")
|
||||
static D3D11_SAMPLER_DESC samplerDesc =
|
||||
{
|
||||
D3D11_FILTER_MIN_MAG_MIP_LINEAR,
|
||||
D3D11_TEXTURE_ADDRESS_WRAP,
|
||||
D3D11_TEXTURE_ADDRESS_WRAP,
|
||||
D3D11_TEXTURE_ADDRESS_WRAP,
|
||||
0,
|
||||
1,
|
||||
D3D11_COMPARISON_NEVER,
|
||||
{ 0, 0, 0, 0 },
|
||||
0,
|
||||
0,
|
||||
};
|
||||
|
||||
#pragma data_seg(".shadowDepthTexDesc")
|
||||
static D3D11_TEXTURE2D_DESC shadowDepthTexDesc =
|
||||
{
|
||||
2*SHADOW_RES, SHADOW_RES, 1, 1, DXGI_FORMAT_R32_TYPELESS,
|
||||
{ 1, 0 }, D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_DEPTH_STENCIL | D3D11_BIND_SHADER_RESOURCE,
|
||||
0,
|
||||
};
|
||||
|
||||
#pragma data_seg(".shadowEsmTexDesc")
|
||||
static D3D11_TEXTURE2D_DESC shadowEsmTexDesc =
|
||||
{
|
||||
2*SHADOW_RES, SHADOW_RES, 1, 1, DXGI_FORMAT_R32_FLOAT,
|
||||
{ 1, 0 }, D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_RENDER_TARGET | D3D11_BIND_SHADER_RESOURCE,
|
||||
0,
|
||||
};
|
||||
|
||||
#pragma data_seg(".rtTexDesc")
|
||||
static D3D11_TEXTURE2D_DESC rtTexDesc =
|
||||
{
|
||||
RES_MULTIPLIER * SCREENWIDTH, RES_MULTIPLIER * SCREENHEIGHT, 0, 1, DXGI_FORMAT_R16G16B16A16_FLOAT,
|
||||
{ 1, 0 }, D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_RENDER_TARGET | D3D11_BIND_SHADER_RESOURCE,
|
||||
0, D3D11_RESOURCE_MISC_GENERATE_MIPS
|
||||
};
|
||||
|
||||
#pragma data_seg(".aoTexDesc")
|
||||
static D3D11_TEXTURE2D_DESC aoTexDesc =
|
||||
{
|
||||
RES_MULTIPLIER * SCREENWIDTH, RES_MULTIPLIER * SCREENHEIGHT, 1, 1, DXGI_FORMAT_R32_FLOAT,
|
||||
{ 1, 0 }, D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_RENDER_TARGET | D3D11_BIND_SHADER_RESOURCE,
|
||||
0, 0
|
||||
};
|
||||
|
||||
#pragma data_seg(".depthBufferSRVdesc")
|
||||
static D3D11_SHADER_RESOURCE_VIEW_DESC depthBufferSRVdesc =
|
||||
{
|
||||
DXGI_FORMAT_R32_FLOAT,
|
||||
D3D11_SRV_DIMENSION_TEXTURE2D,
|
||||
{ 0, 1 }
|
||||
};
|
||||
|
||||
#pragma data_seg(".constantBuffer2Desc")
|
||||
static D3D11_BUFFER_DESC constantBuffer2Desc =
|
||||
{
|
||||
160,
|
||||
D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_CONSTANT_BUFFER,
|
||||
0,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
#pragma data_seg(".constantBufferTempDesc")
|
||||
static D3D11_BUFFER_DESC constantBufferTempDesc =
|
||||
{
|
||||
160,
|
||||
D3D11_USAGE_DEFAULT,
|
||||
D3D11_BIND_STREAM_OUTPUT,
|
||||
0,
|
||||
0,
|
||||
0
|
||||
};
|
||||
|
||||
#pragma data_seg(".shadowViewport")
|
||||
static D3D11_VIEWPORT shadowViewport =
|
||||
{
|
||||
0.0f,
|
||||
0.0f,
|
||||
2*SHADOW_RES,
|
||||
SHADOW_RES,
|
||||
0.0f,
|
||||
1.0f,
|
||||
};
|
||||
|
||||
#pragma data_seg(".doubleViewport")
|
||||
static D3D11_VIEWPORT doubleViewport =
|
||||
{
|
||||
0.0f,
|
||||
0.0f,
|
||||
RES_MULTIPLIER * SCREENWIDTH,
|
||||
RES_MULTIPLIER * SCREENHEIGHT,
|
||||
0.0f,
|
||||
1.0f,
|
||||
};
|
||||
|
||||
#pragma data_seg(".CameraSODeclarations")
|
||||
static D3D11_SO_DECLARATION_ENTRY CameraSODeclarations[] =
|
||||
{
|
||||
{ 0, "d", 0, 0, 4, 0 },
|
||||
{ 0, "e", 0, 0, 4, 0 },
|
||||
{ 0, "u", 0, 0, 4, 0 },
|
||||
{ 0, "d", 1, 0, 4, 1 },
|
||||
{ 0, "e", 1, 0, 4, 1 },
|
||||
{ 0, "u", 1, 0, 4, 1 },
|
||||
};
|
||||
|
||||
#pragma data_seg(".CameraStrides")
|
||||
static UINT CameraStrides[] = { 48, 48 };
|
||||
61
aquarium/src/intro/intro/init.h
Normal file
61
aquarium/src/intro/intro/init.h
Normal file
@@ -0,0 +1,61 @@
|
||||
#pragma once
|
||||
|
||||
#pragma code_seg(".CreateTexture")
|
||||
|
||||
static void CreateTexture(STexture& tex, D3D11_TEXTURE2D_DESC* desc = &standardTexDesc)
|
||||
{
|
||||
device->CreateTexture2D(desc, nullptr, &tex.TEX);
|
||||
device->CreateShaderResourceView(tex.TEX, nullptr, &tex.SRV);
|
||||
device->CreateRenderTargetView(tex.TEX, nullptr, &tex.RTV);
|
||||
device->CreateUnorderedAccessView(tex.TEX, nullptr, &tex.UAV);
|
||||
}
|
||||
|
||||
void DoTexture(ID3D11ComputeShader* shader)
|
||||
{
|
||||
context->CSSetShader(shader, nullptr, 0);
|
||||
context->CSSetShaderResources(0, 1, &tex2.SRV);
|
||||
context->CSSetUnorderedAccessViews(0, 1, &tex1.UAV, nullptr);
|
||||
context->Dispatch(2048 / 16, 2048 / 16, 1);
|
||||
context->CSSetUnorderedAccessViews(0, 1, reinterpret_cast<ID3D11UnorderedAccessView* const*>(zero), nullptr);
|
||||
context->CSSetShaderResources(0, 1, reinterpret_cast<ID3D11ShaderResourceView* const*>(zero));
|
||||
const auto temp = tex2;
|
||||
tex2 = tex1;
|
||||
tex1 = temp;
|
||||
}
|
||||
|
||||
#pragma code_seg(".IntroInit")
|
||||
INLINE void IntroInit()
|
||||
{
|
||||
Log("IntroInit");
|
||||
|
||||
CreateTexture(rt, &rtTexDesc);
|
||||
CreateTexture(mrt1, &rtTexDesc);
|
||||
CreateTexture(mrt2, &rtTexDesc);
|
||||
CreateTexture(mrt3, &rtTexDesc);
|
||||
CreateTexture(ao, &aoTexDesc);
|
||||
CreateTexture(shadow1, &shadowDepthTexDesc);
|
||||
CreateTexture(shadow2, &shadowEsmTexDesc);
|
||||
CreateTexture(shadow3, &shadowEsmTexDesc);
|
||||
rtvs[0] = mrt1.RTV;
|
||||
rtvs[1] = mrt2.RTV;
|
||||
rtvs[2] = mrt3.RTV;
|
||||
standardTexDesc.Width = 2048;
|
||||
standardTexDesc.Height = 2048;
|
||||
CreateTexture(tex1);
|
||||
CreateTexture(tex2);
|
||||
|
||||
device->CreateBuffer(&constantBuffer2Desc, nullptr, &cameraBuffer);
|
||||
device->CreateBuffer(&constantBuffer2Desc, nullptr, &lightBuffer);
|
||||
device->CreateBuffer(&constantBufferTempDesc, nullptr, &constantBufferTemp[0]);
|
||||
device->CreateBuffer(&constantBufferTempDesc, nullptr, &constantBufferTemp[1]);
|
||||
device->CreateShaderResourceView(depthStencilBuffer, &depthBufferSRVdesc, &depthBufferSrv);
|
||||
device->CreateSamplerState(&samplerDesc, &samplerState);
|
||||
device->CreateDepthStencilView(shadow1.TEX, &depthStencilViewDesc, &shadowDepthStencilView);
|
||||
|
||||
//for (int i = 0; i < 4096; ++i)
|
||||
{
|
||||
DoTexture(cs_Coral);
|
||||
}
|
||||
|
||||
DoTexture(cs_Stone);
|
||||
}
|
||||
47
aquarium/src/intro/intro/sync.xml
Normal file
47
aquarium/src/intro/intro/sync.xml
Normal file
@@ -0,0 +1,47 @@
|
||||
<Audio>
|
||||
<Channel Name="time">
|
||||
<Value Row="0" Mode="Linear" Value="0" />
|
||||
<Value Row="1984" Mode="Step" Value="31" />
|
||||
</Channel>
|
||||
<Channel Name="cameraPos_x">
|
||||
<Value Row="0" Mode="Linear" Value="-100" />
|
||||
<Value Row="24" Mode="Step" Value="5" />
|
||||
</Channel>
|
||||
<Channel Name="cameraPos_y">
|
||||
<Value Row="0" Mode="Linear" Value="-40" />
|
||||
<Value Row="192" Mode="Step" Value="-80" />
|
||||
</Channel>
|
||||
<Channel Name="cameraPos_z">
|
||||
<Value Row="0" Mode="Linear" Value="-120" />
|
||||
<Value Row="23" Mode="Step" Value="-150" />
|
||||
<Value Row="24" Mode="EaseIn" Value="-150" />
|
||||
<Value Row="192" Mode="Step" Value="-70" />
|
||||
<Value Row="193" Mode="Linear" Value="-70" />
|
||||
<Value Row="256" Mode="Step" Value="-50" />
|
||||
<Value Row="257" Mode="Linear" Value="-50" />
|
||||
<Value Row="320" Mode="Step" Value="50" />
|
||||
</Channel>
|
||||
<Channel Name="dummy1">
|
||||
</Channel>
|
||||
<Channel Name="cameraAt_x">
|
||||
<Value Row="0" Mode="Linear" Value="0" />
|
||||
<Value Row="192" Mode="Step" Value="100" />
|
||||
</Channel>
|
||||
<Channel Name="cameraAt_y">
|
||||
<Value Row="0" Mode="Linear" Value="-60" />
|
||||
<Value Row="256" Mode="Step" Value="-80" />
|
||||
</Channel>
|
||||
<Channel Name="cameraAt_z">
|
||||
</Channel>
|
||||
<Channel Name="dummy2">
|
||||
</Channel>
|
||||
<Channel Name="cameraUp_x">
|
||||
<Value Row="0" Mode="Step" Value="0" />
|
||||
</Channel>
|
||||
<Channel Name="cameraUp_y">
|
||||
<Value Row="0" Mode="Step" Value="1" />
|
||||
</Channel>
|
||||
<Channel Name="cameraUp_z">
|
||||
<Value Row="0" Mode="Step" Value="0" />
|
||||
</Channel>
|
||||
</Audio>
|
||||
106
aquarium/src/intro/intro/update.h
Normal file
106
aquarium/src/intro/intro/update.h
Normal file
@@ -0,0 +1,106 @@
|
||||
#pragma once
|
||||
|
||||
#pragma code_seg(".IntroUpdate")
|
||||
INLINE void IntroUpdate(float _introPosition)
|
||||
{
|
||||
context->PSSetSamplers(0, 1, &samplerState);
|
||||
|
||||
context->CSSetConstantBuffers(0, 1, &SyncBuffer);
|
||||
context->CSSetConstantBuffers(1, 1, &cameraBuffer);
|
||||
context->CSSetConstantBuffers(2, 1, &lightBuffer);
|
||||
|
||||
context->PSSetConstantBuffers(0, 1, &SyncBuffer);
|
||||
context->PSSetConstantBuffers(1, 1, &cameraBuffer);
|
||||
context->PSSetConstantBuffers(2, 1, &lightBuffer);
|
||||
|
||||
context->GSSetConstantBuffers(0, 1, &SyncBuffer);
|
||||
context->GSSetConstantBuffers(1, 1, &cameraBuffer);
|
||||
context->GSSetConstantBuffers(2, 1, &lightBuffer);
|
||||
|
||||
context->VSSetConstantBuffers(0, 1, &SyncBuffer);
|
||||
context->VSSetConstantBuffers(1, 1, &cameraBuffer);
|
||||
context->VSSetConstantBuffers(2, 1, &lightBuffer);
|
||||
|
||||
context->SOSetTargets(2, constantBufferTemp, reinterpret_cast<UINT*>(zero));
|
||||
context->IASetPrimitiveTopology(D3D11_PRIMITIVE_TOPOLOGY_POINTLIST);
|
||||
|
||||
context->VSSetShader(vs_Camera, nullptr, 0);
|
||||
context->GSSetShader(gs_Camera, nullptr, 0);
|
||||
context->Draw(1, 0);
|
||||
context->CopyResource(cameraBuffer, constantBufferTemp[0]);
|
||||
context->CopyResource(lightBuffer, constantBufferTemp[1]);
|
||||
|
||||
context->SOSetTargets(0, reinterpret_cast<ID3D11Buffer* const *>(zero), reinterpret_cast<UINT*>(zero));
|
||||
|
||||
DoTexture(cs_Caustics);
|
||||
|
||||
context->ClearRenderTargetView(mrt1.RTV, one);
|
||||
context->ClearRenderTargetView(mrt2.RTV, one);
|
||||
context->ClearRenderTargetView(mrt3.RTV, one);
|
||||
context->OMSetDepthStencilState(depthTestWrite, 0);
|
||||
context->PSSetShaderResources(0, 1, &tex2.SRV);
|
||||
|
||||
context->IASetPrimitiveTopology(D3D11_PRIMITIVE_TOPOLOGY_POINTLIST);
|
||||
context->RSSetViewports(1, &shadowViewport);
|
||||
context->ClearDepthStencilView(shadowDepthStencilView, D3D11_CLEAR_DEPTH, 1, 0);
|
||||
context->OMSetRenderTargets(1, &shadow2.RTV, shadowDepthStencilView);
|
||||
context->GSSetConstantBuffers(1, 1, &lightBuffer);
|
||||
context->PSSetConstantBuffers(1, 1, &lightBuffer);
|
||||
context->VSSetShader(vs_DrawHulls, nullptr, 0);
|
||||
context->GSSetShader(gs_DrawHulls, nullptr, 0);
|
||||
context->PSSetShader(ps_DrawDepth, nullptr, 0);
|
||||
context->Draw(1024, 0);
|
||||
context->GSSetShader(nullptr, nullptr, 0);
|
||||
|
||||
context->IASetPrimitiveTopology(D3D11_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP);
|
||||
context->VSSetShader(vs_ScreenQuad, nullptr, 0);
|
||||
context->PSSetShader(ps_BlurH, nullptr, 0);
|
||||
context->OMSetRenderTargets(1, &shadow3.RTV, nullptr);
|
||||
context->PSSetShaderResources(4, 1, &shadow2.SRV);
|
||||
context->Draw(4, 0);
|
||||
context->PSSetShaderResources(0, 6, reinterpret_cast<ID3D11ShaderResourceView* const*>(zero));
|
||||
context->PSSetShader(ps_BlurV, nullptr, 0);
|
||||
context->OMSetRenderTargets(1, &shadow2.RTV, nullptr);
|
||||
context->PSSetShaderResources(4, 1, &shadow3.SRV);
|
||||
context->Draw(4, 0);
|
||||
|
||||
context->IASetPrimitiveTopology(D3D11_PRIMITIVE_TOPOLOGY_POINTLIST);
|
||||
context->RSSetViewports(1, &doubleViewport);
|
||||
context->ClearDepthStencilView(depthStencilView, D3D11_CLEAR_DEPTH, 1, 0);
|
||||
context->OMSetRenderTargets(3, rtvs, depthStencilView);
|
||||
context->GSSetConstantBuffers(1, 1, &cameraBuffer);
|
||||
context->PSSetConstantBuffers(1, 1, &cameraBuffer);
|
||||
context->VSSetShader(vs_DrawHulls, nullptr, 0);
|
||||
context->GSSetShader(gs_DrawHulls, nullptr, 0);
|
||||
context->PSSetShader(ps_DrawHulls, nullptr, 0);
|
||||
context->Draw(1024, 0);
|
||||
context->GSSetShader(nullptr, nullptr, 0);
|
||||
|
||||
context->IASetPrimitiveTopology(D3D11_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP);
|
||||
context->VSSetShader(vs_ScreenQuad, nullptr, 0);
|
||||
context->OMSetRenderTargets(1, &ao.RTV, nullptr);
|
||||
context->PSSetShaderResources(0, 1, &mrt1.SRV);
|
||||
context->PSSetShaderResources(1, 1, &mrt2.SRV);
|
||||
context->PSSetShaderResources(2, 1, &mrt3.SRV);
|
||||
context->PSSetShaderResources(3, 1, &depthBufferSrv);
|
||||
context->PSSetShaderResources(4, 1, &shadow2.SRV);
|
||||
context->PSSetShaderResources(5, 1, &tex2.SRV);
|
||||
context->PSSetShader(ps_AmbientOcclussion, nullptr, 0);
|
||||
context->Draw(4, 0);
|
||||
|
||||
context->OMSetRenderTargets(1, &rt.RTV, nullptr);
|
||||
context->PSSetShaderResources(3, 1, &ao.SRV);
|
||||
context->PSSetShader(ps_PostProcess, nullptr, 0);
|
||||
context->Draw(4, 0);
|
||||
|
||||
context->GenerateMips(rt.SRV);
|
||||
|
||||
context->RSSetViewports(1, &swapChainViewport);
|
||||
context->OMSetRenderTargets(1, &backBufferRTV, nullptr);
|
||||
context->PSSetShaderResources(0, 1, &rt.SRV);
|
||||
context->PSSetShader(ps_ToGamma, nullptr, 0);
|
||||
context->Draw(4, 0);
|
||||
context->PSSetShaderResources(0, 6, reinterpret_cast<ID3D11ShaderResourceView* const*>(zero));
|
||||
|
||||
swapChain->Present(1, 0);
|
||||
}
|
||||
19
aquarium/src/intro/main.cpp
Normal file
19
aquarium/src/intro/main.cpp
Normal file
@@ -0,0 +1,19 @@
|
||||
#include "framework/framework.h"
|
||||
#include "intro/data.h"
|
||||
#include "intro/init.h"
|
||||
#include "intro/update.h"
|
||||
|
||||
int _cdecl main(int argc, char* argv[])
|
||||
{
|
||||
FrameworkInit();
|
||||
|
||||
do
|
||||
{
|
||||
FrameworkUpdate();
|
||||
} while (FrameworkContinueExecuting());
|
||||
|
||||
FrameworkDispose();
|
||||
ExitProcess(0);
|
||||
return 0;
|
||||
}
|
||||
|
||||
38
aquarium/src/intro/shaders/camera.hlsl
Normal file
38
aquarium/src/intro/shaders/camera.hlsl
Normal file
@@ -0,0 +1,38 @@
|
||||
//[entrypoint(vs_gs_so, 6, 2)]
|
||||
void Camera(
|
||||
out float4 cd : d0,
|
||||
out float4 ce : e0,
|
||||
out float4 cu : u0,
|
||||
out float4 ld : d1,
|
||||
out float4 le : e1,
|
||||
out float4 lu : u1)
|
||||
{
|
||||
cd = float4(normalize(_s.cameraAt - _s.cameraPos), 0);
|
||||
ce = float4(_s.cameraPos, 0);
|
||||
cu = float4(normalize(_s.cameraUp), 0);
|
||||
ld = float4(0, -1, 0, 0);
|
||||
le = float4(0, 300, 0, 0);
|
||||
lu = float4(0, 0, 1, 0);
|
||||
}
|
||||
|
||||
float4 project(float3 v, Cam c)
|
||||
{
|
||||
float3
|
||||
u = c._u.xyz,
|
||||
z = c._d.xyz,
|
||||
e = c._e.xyz,
|
||||
x = cross(u, z),
|
||||
y = cross(z, x);
|
||||
|
||||
return mul(mul(float4(v, 1.0),
|
||||
transpose(float4x4(
|
||||
x, -dot(x, e),
|
||||
y, -dot(y, e),
|
||||
z, -dot(z, e),
|
||||
0, 0, 0, 1))),
|
||||
float4x4(
|
||||
1, 0, 0, 0,
|
||||
0, 1.6, 0, 0,
|
||||
0, 0, 1, 1,
|
||||
0, 0, -1, 0));
|
||||
}
|
||||
173
aquarium/src/intro/shaders/functions.hlsl
Normal file
173
aquarium/src/intro/shaders/functions.hlsl
Normal file
@@ -0,0 +1,173 @@
|
||||
float2 mod2(float2 x, float2 y)
|
||||
{
|
||||
return x - y * floor(x / y);
|
||||
}
|
||||
|
||||
float mod(float x, float y)
|
||||
{
|
||||
return x - y * floor(x / y);
|
||||
}
|
||||
|
||||
// *** Use this for integer stepped ranges, ie Value-Noise/Perlin noise functions.
|
||||
//#define HASHSCALE1 .1031
|
||||
//#define HASHSCALE3 float3(.1031, .1030, .0973)
|
||||
//#define HASHSCALE4 float4(.1031, .1030, .0973, .1099)
|
||||
|
||||
// For smaller input rangers like audio tick or 0-1 UVs use these...
|
||||
#define HASHSCALE1 443.8975
|
||||
#define HASHSCALE3 float3(443.897, 441.423, 437.195)
|
||||
#define HASHSCALE4 float4(443.897, 441.423, 437.195, 444.129)
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
// 1 out, 1 in...
|
||||
float hash11(float p)
|
||||
{
|
||||
float3 p3 = frac(p * HASHSCALE1);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.x + p3.y) * p3.z);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
// 1 out, 2 in...
|
||||
float hash12(float2 p)
|
||||
{
|
||||
float3 p3 = frac(p.xyx * HASHSCALE1);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.x + p3.y) * p3.z);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
// 1 out, 3 in...
|
||||
float hash13(float3 p3)
|
||||
{
|
||||
p3 = frac(p3 * HASHSCALE1);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.x + p3.y) * p3.z);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
// 2 out, 1 in...
|
||||
float2 hash21(float p)
|
||||
{
|
||||
float3 p3 = frac(p * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.xx + p3.yz)*p3.zy);
|
||||
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
/// 2 out, 2 in...
|
||||
float2 hash22(float2 p)
|
||||
{
|
||||
float3 p3 = frac(p.xyx * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.xx + p3.yz)*p3.zy);
|
||||
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
/// 2 out, 3 in...
|
||||
float2 hash23(float3 p3)
|
||||
{
|
||||
p3 = frac(p3 * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.xx + p3.yz)*p3.zy);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
// 3 out, 1 in...
|
||||
float3 hash31(float p)
|
||||
{
|
||||
float3 p3 = frac(p * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yzx + 19.19);
|
||||
return frac((p3.xxy + p3.yzz)*p3.zyx);
|
||||
}
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
/// 3 out, 2 in...
|
||||
float3 hash32(float2 p)
|
||||
{
|
||||
float3 p3 = frac(p.xyx * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yxz + 19.19);
|
||||
return frac((p3.xxy + p3.yzz)*p3.zyx);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
/// 3 out, 3 in...
|
||||
float3 hash33(float3 p3)
|
||||
{
|
||||
p3 = frac(p3 * HASHSCALE3);
|
||||
p3 += dot(p3, p3.yxz + 19.19);
|
||||
return frac((p3.xxy + p3.yxx)*p3.zyx);
|
||||
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
// 4 out, 1 in...
|
||||
float4 hash41(float p)
|
||||
{
|
||||
float4 p4 = frac(p * HASHSCALE4);
|
||||
p4 += dot(p4, p4.wzxy + 19.19);
|
||||
return frac((p4.xxyz + p4.yzzw)*p4.zywx);
|
||||
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
// 4 out, 2 in...
|
||||
float4 hash42(float2 p)
|
||||
{
|
||||
float4 p4 = frac(p.xyxy * HASHSCALE4);
|
||||
p4 += dot(p4, p4.wzxy + 19.19);
|
||||
return frac((p4.xxyz + p4.yzzw)*p4.zywx);
|
||||
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
// 4 out, 3 in...
|
||||
float4 hash43(float3 p)
|
||||
{
|
||||
float4 p4 = frac(p.xyzx * HASHSCALE4);
|
||||
p4 += dot(p4, p4.wzxy + 19.19);
|
||||
return frac((p4.xxyz + p4.yzzw)*p4.zywx);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------
|
||||
// 4 out, 4 in...
|
||||
float4 hash44(float4 p4)
|
||||
{
|
||||
p4 = frac(p4 * HASHSCALE4);
|
||||
p4 += dot(p4, p4.wzxy + 19.19);
|
||||
return frac((p4.xxyz + p4.yzzw)*p4.zywx);
|
||||
}
|
||||
|
||||
|
||||
float noise13( in float3 x )
|
||||
{
|
||||
float3 p = floor(x);
|
||||
float3 f = frac(x);
|
||||
f = f*f*(3.0-2.0*f);
|
||||
|
||||
return lerp(lerp(lerp( hash13(p+float3(0,0,0)),
|
||||
hash13(p+float3(1,0,0)),f.x),
|
||||
lerp( hash13(p+float3(0,1,0)),
|
||||
hash13(p+float3(1,1,0)),f.x),f.y),
|
||||
lerp(lerp( hash13(p+float3(0,0,1)),
|
||||
hash13(p+float3(1,0,1)),f.x),
|
||||
lerp( hash13(p+float3(0,1,1)),
|
||||
hash13(p+float3(1,1,1)),f.x),f.y),f.z);
|
||||
}
|
||||
|
||||
float3 noise31( in float x )
|
||||
{
|
||||
float p = floor(x);
|
||||
float f = frac(x);
|
||||
f = f*f*(3.0-2.0*f);
|
||||
return lerp(hash31(p), hash31(p+1),f);
|
||||
}
|
||||
|
||||
// rotation
|
||||
void pR(inout float2 p, float a)
|
||||
{
|
||||
p = cos(a)*p+sin(a)*float2(p.y,-p.x);
|
||||
}
|
||||
21
aquarium/src/intro/shaders/intro.hlsl
Normal file
21
aquarium/src/intro/shaders/intro.hlsl
Normal file
@@ -0,0 +1,21 @@
|
||||
#include "structs.hlsl"
|
||||
|
||||
RWTexture2D<float4> o2d0 : register(u0);
|
||||
Texture2D t2d0 : register(t0);
|
||||
Texture2D t2d1 : register(t1);
|
||||
Texture2D t2d2 : register(t2);
|
||||
Texture2D t2d3 : register(t3);
|
||||
Texture2D t2d4 : register(t4);
|
||||
Texture2D t2d5 : register(t5);
|
||||
SamplerState s0 : register(s0);
|
||||
|
||||
cbuffer sb : register(b0) { Sync _s; };
|
||||
cbuffer cb : register(b1) { Cam _c; };
|
||||
cbuffer cb : register(b2) { Cam _l; };
|
||||
|
||||
#include "functions.hlsl"
|
||||
#include "textures.hlsl"
|
||||
#include "camera.hlsl"
|
||||
#include "scene.hlsl"
|
||||
#include "shadow.hlsl"
|
||||
#include "postprocessing.hlsl"
|
||||
118
aquarium/src/intro/shaders/postprocessing.hlsl
Normal file
118
aquarium/src/intro/shaders/postprocessing.hlsl
Normal file
@@ -0,0 +1,118 @@
|
||||
//[entrypoint(vs)]
|
||||
void vs_ScreenQuad(uint i : SV_VertexID, out float2 uv : TEXCOORD, out float4 p : SV_Position)
|
||||
{
|
||||
uv = float2(i / 2, i % 2);
|
||||
p = float4(uv * 2 - 1, 0, 1);
|
||||
uv.y = 1 - uv.y;
|
||||
}
|
||||
|
||||
float ao(in float2 uv, float rad, float strength)
|
||||
{
|
||||
float3 ep = t2d1.Sample(s0, uv).xyz;
|
||||
float3 n = t2d2.Sample(s0, uv).xyz;
|
||||
float bl = 0;
|
||||
float i = 0;
|
||||
for (int j = 0; j < 32; ++j)
|
||||
{
|
||||
float3 se = noise31(j) - .5;
|
||||
float imp = dot(se, n);
|
||||
if (imp < 0)
|
||||
{
|
||||
se *= -1;
|
||||
imp *= -1;
|
||||
}
|
||||
i += imp;
|
||||
se = ep + rad * se;
|
||||
float3 ss4 = project(se, _c).xyw;
|
||||
ss4.xy = ss4.xy / ss4.z * float2(.5, -.5) + .5;
|
||||
float sz = t2d3.Sample(s0, ss4.xy).x * 500 + .3;
|
||||
float zd = strength*max(length(se - _s.cameraPos) - sz, 0) / rad;
|
||||
bl += imp / (1.0 + zd*zd);
|
||||
}
|
||||
return saturate(bl / i);
|
||||
}
|
||||
|
||||
//[entrypoint(ps)]
|
||||
float ps_AmbientOcclussion(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
return ao(uv, 0.3, 50) * ao(uv, 2, 10) * ao(uv, 5, 5);
|
||||
}
|
||||
|
||||
float sampleLight(float3 p, float3 n)
|
||||
{
|
||||
float3 lv = float3(0, 300, 0) - p; // light vector
|
||||
float d = length(lv) / 500; // distance between p and light
|
||||
lv = normalize(lv); // direction from p to light
|
||||
|
||||
float3 luv = project(p, _l).xyw;
|
||||
luv.xy = luv.xy / luv.z * float2(.5, -.5) + .5; // shadow map UV
|
||||
float s = exp(-80 * d)*t2d4.Sample(s0, luv.xy).x; // closest distance to light
|
||||
float df = max(dot(n, lv), 0); // diffuse
|
||||
|
||||
return min(s, df)*1.2;
|
||||
}
|
||||
|
||||
float fog(float3 p)
|
||||
{
|
||||
float l = 0;
|
||||
float3 rd = (_c._e.xyz - p) / 128;
|
||||
float intensity = 0.7;
|
||||
for (int i = 0; i < 128; ++i)
|
||||
{
|
||||
l += lerp(1, sampleLight(p, normalize(float3(0, 300, 0) - p)), intensity);
|
||||
p += rd;
|
||||
}
|
||||
//return length(rd)/500;
|
||||
return pow(l / 128, 8);
|
||||
}
|
||||
|
||||
float3 colorize(float type, float3 p, float3 n)
|
||||
{
|
||||
if (type == 0)
|
||||
{
|
||||
return float3(.3, .7, .3);
|
||||
}
|
||||
else if (type == 1)
|
||||
{
|
||||
return
|
||||
pow(t2d5.Sample(s0, 1 + p.yz*.15).z*abs(n.x) +
|
||||
t2d5.Sample(s0, 1 + p.xz*.15).z*abs(n.y) +
|
||||
t2d5.Sample(s0, 1 + p.xy*.15).z*abs(n.z), 2)*
|
||||
float3(0.8, 0.2, 0.1);
|
||||
}
|
||||
else if (type == 2)
|
||||
{
|
||||
return float3(0.0, 0.05, 0.1);
|
||||
}
|
||||
else if (type == 3)
|
||||
{
|
||||
return t2d5.Sample(s0, 1 + p.xz*.2).z*float3(0.4, 0.2, 0.1);
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
//[entrypoint(ps)]
|
||||
float4 ps_PostProcess(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
float3 c1 = t2d1.Sample(s0, uv).xyz;
|
||||
float3 c2 = t2d2.Sample(s0, uv).xyz;
|
||||
float3 c0 = colorize(t2d0.Sample(s0, uv).x, c1, c2);
|
||||
float cx = pow(t2d5.Sample(s0, c1.xz*.02).w + .5,4) * max(0, c2.y); // caustics
|
||||
float t = _s.time;
|
||||
float f = fog(c1);
|
||||
float a = t2d3.Sample(s0, uv).x;
|
||||
float fade = 1.0;//max(0, min(1, t) * min(1, 30-t));
|
||||
float l = sampleLight(c1, c2);
|
||||
float3 color = c0 * a * f * max(l, 0.1);
|
||||
color += lerp(0.01, cx, l) * f;
|
||||
|
||||
float df = length(_c._e.xyz - c1) / 500;
|
||||
color = lerp(color, float3(0.05, 0.1, 0.3), df);
|
||||
return float4(color * fade, 1);
|
||||
}
|
||||
|
||||
//[entrypoint(ps)]
|
||||
float4 ps_ToGamma(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
return t2d0.SampleLevel(s0, uv, 1); // convert to DXGI_FORMAT_B8G8R8A8_UNORM_SRGB
|
||||
}
|
||||
193
aquarium/src/intro/shaders/scene.hlsl
Normal file
193
aquarium/src/intro/shaders/scene.hlsl
Normal file
@@ -0,0 +1,193 @@
|
||||
//[entrypoint(vs)]
|
||||
void vs_DrawHulls(uint i : SV_VertexID, out Hull h)
|
||||
{
|
||||
h.rotate = float3x3(1, 0, 0, 0, 1, 0, 0, 0, 1);
|
||||
if (i < 4) // aquarium bounds
|
||||
{
|
||||
h.position = float3((i < 2)*((i > 0) - .5) * 2, -(i == 3), i == 2)*float3(200, 100, 125);
|
||||
h.scale = (abs(h.position) == 0) * float3(390, 190, 240) + 10;
|
||||
h.type = i == 3 ? 3 : 2;
|
||||
}
|
||||
else if (i < 23)
|
||||
{
|
||||
h.position = (hash32(float2(i.x, 10)) - 0.5) * float3(200, -90, 67);
|
||||
h.position.y -= 50;
|
||||
h.scale = hash12(float2(i.x, 3)) * 60 + 10;
|
||||
h.type = 1;
|
||||
float rot = hash12(float2(i.x, 2));
|
||||
float s, c;
|
||||
sincos(rot, s, c);
|
||||
h.rotate = float3x3(
|
||||
c, 0, s,
|
||||
0, 1, 0,
|
||||
-s, 0, c);
|
||||
}
|
||||
else
|
||||
{
|
||||
h.position = normalize(hash32(float2(i.x + 7, 5)) - 0.5);
|
||||
h.position *= (hash12(float2(i.x, 5))*.5 + .5) * float3(200, 100, 125);
|
||||
pR(h.position.xz, _s.time * length(h.position.xz) * 0.01);
|
||||
h.type = 0;
|
||||
float rot = hash12(float2(i.x, 2)) + (hash12(float2(i.x + 11, 3)) - 0.5) * _s.time * 10;
|
||||
float s, c;
|
||||
sincos(rot, s, c);
|
||||
h.rotate = float3x3(
|
||||
c, 0, s,
|
||||
0, 1, 0,
|
||||
-s, 0, c);
|
||||
h.scale = hash12(float2(i.x, 4)) * 2 + .5;
|
||||
h.scale.x *= 3;
|
||||
h.scale.z *= 0.2;
|
||||
}
|
||||
h.o = 0;
|
||||
h.world = 0;
|
||||
}
|
||||
|
||||
//[entrypoint(gs)]
|
||||
[maxvertexcount(14)] void gs_DrawHulls(point Hull hulls[1], inout TriangleStream<Hull> o)
|
||||
{
|
||||
Hull h = hulls[0];
|
||||
for (uint i = 0; i < 14; ++i)
|
||||
{
|
||||
uint b = 1 << i;
|
||||
float3 v = float3(
|
||||
(0x287a & b) != 0,
|
||||
(0x02af & b) != 0,
|
||||
(0x31e3 & b) != 0) - 0.5f;
|
||||
|
||||
v *= h.scale;
|
||||
v = mul(v, h.rotate);
|
||||
v += h.position;
|
||||
|
||||
h.world = v;
|
||||
h.o = project(v, _c);
|
||||
o.Append(h);
|
||||
}
|
||||
o.RestartStrip();
|
||||
}
|
||||
|
||||
float vmax(float3 v) {
|
||||
return max(max(v.x, v.y), v.z);
|
||||
}
|
||||
|
||||
// Box: correct distance to corners
|
||||
float fBox(float3 p, float3 b) {
|
||||
float3 d = abs(p) - b;
|
||||
return length(max(d, 0)) + vmax(min(d, 0));
|
||||
}
|
||||
|
||||
float sdEllipsoid(in float3 p, in float3 r)
|
||||
{
|
||||
float k0 = length(p / r);
|
||||
return k0*(k0 - 1) / length(p / (r*r));
|
||||
}
|
||||
|
||||
float opSmoothUnion(float d1, float d2, float k)
|
||||
{
|
||||
float h = clamp(0.5 + 0.5*(d2 - d1) / k, 0.0, 1.0);
|
||||
return lerp(d2, d1, h) - k*h*(1.0 - h);
|
||||
}
|
||||
|
||||
float atz(float2 p)
|
||||
{
|
||||
float2 a = abs(p);
|
||||
return min(max(max(
|
||||
min(abs(mod(p.x + .067, .134) - .067), max(a.x, a.y) - .1),
|
||||
-min(length(p - float2(0, .03)) - .06, max(a.x, abs(p.y + .02) - .03) - .04)
|
||||
), abs(a.x + a.y) - .4), abs(abs(a.x + a.y) - .41) + .01) - 0.02;
|
||||
}
|
||||
|
||||
float atz3(in float3 p, in float h)
|
||||
{
|
||||
float d = atz(p.xy);
|
||||
float2 w = float2(d, abs(p.z) - h);
|
||||
return min(max(w.x, w.y), 0.0) + length(max(w, 0.0));
|
||||
}
|
||||
|
||||
float map(Hull h, float3 p)
|
||||
{
|
||||
float3 q = p;
|
||||
q -= h.position;
|
||||
q = mul(q, transpose(h.rotate));
|
||||
|
||||
float dist = 0;
|
||||
if (h.type == 1)
|
||||
{
|
||||
q /= h.scale.x;
|
||||
float fbm =
|
||||
0.3 * (noise13(q * 7) - .5) +
|
||||
0.1 * (noise13(q * 20) - .5) +
|
||||
0.02 * (noise13(q * 50) - .5) +
|
||||
0.008 * (noise13(q * 125) - .5) +
|
||||
0.001 * (noise13(q * 500) - .5);
|
||||
dist = length(q) - .5 + fbm*.5;
|
||||
dist *= h.scale.x;
|
||||
}
|
||||
else if (h.type >= 2)
|
||||
{
|
||||
float fbm =
|
||||
1.0 * (noise13(q * .1) - .5) +
|
||||
0.5 * (noise13(q * 1) - .5) +
|
||||
0.3 * (noise13(q * 2) - .5) +
|
||||
0.1 * (noise13(q * 5) - .5);
|
||||
dist = fBox(q, h.scale * .5) - fbm*.5;
|
||||
}
|
||||
else
|
||||
{
|
||||
dist = sdEllipsoid(q, h.scale*float3(.4, .5, .5));
|
||||
dist = opSmoothUnion(dist, fBox(q + float3(h.scale.x*.85, 0, 0), h.scale*float3(.0625, .1, .05)), 4);
|
||||
/*q /= h.scale.x;
|
||||
dist = atz3(q, 0.05) - 0.005;
|
||||
dist *= h.scale.x * 0.7;*/
|
||||
}
|
||||
return dist;
|
||||
}
|
||||
|
||||
float3 normal(Hull h, float3 p)
|
||||
{
|
||||
float2 e = float2(0.001, 0);
|
||||
return normalize(float3(
|
||||
map(h, p + e.xyy) - map(h, p - e.xyy),
|
||||
map(h, p + e.yxy) - map(h, p - e.yxy),
|
||||
map(h, p + e.yyx) - map(h, p - e.yyx)));
|
||||
}
|
||||
|
||||
bool raymarch(in Hull h, in int iters, out float3 rd, out float mint)
|
||||
{
|
||||
rd = normalize(h.world - _c._e.xyz);
|
||||
float t = 0.0, lastm = 500;
|
||||
for (int i = 0; i < iters; ++i)
|
||||
{
|
||||
float m = map(h, h.world + t * rd);
|
||||
t += m;// * 0.7;
|
||||
if (m < lastm)
|
||||
{
|
||||
mint = t;
|
||||
lastm = m;
|
||||
}
|
||||
if (t > length(h.scale) || m < 0.001)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
return lastm < 0.01;
|
||||
}
|
||||
|
||||
//[entrypoint(ps)]
|
||||
void ps_DrawHulls(in Hull h, out float d : SV_Depth, out float4 o0 : SV_Target0, out float4 o1 : SV_Target1, out float4 o2 : SV_Target2)
|
||||
{
|
||||
float3 rd;
|
||||
float t;
|
||||
o0 = o1 = o2 = 0; d = 1;
|
||||
if (raymarch(h, 48, rd, t))
|
||||
{
|
||||
float3 p = h.world + t * rd;
|
||||
float3 n = normal(h, p);
|
||||
d = length(p - _c._e.xyz) / 500;
|
||||
o0 = float4(h.type, 0, 0, 1);
|
||||
o1 = float4(p, 0);
|
||||
o2 = float4(n, 0);
|
||||
return;
|
||||
}
|
||||
discard;
|
||||
}
|
||||
46
aquarium/src/intro/shaders/shadow.hlsl
Normal file
46
aquarium/src/intro/shaders/shadow.hlsl
Normal file
@@ -0,0 +1,46 @@
|
||||
//[entrypoint(ps)]
|
||||
float ps_DrawDepth(in Hull h, out float d : SV_Depth) : SV_Target0
|
||||
{
|
||||
float3 rd;
|
||||
float t;
|
||||
d = 0;
|
||||
if (raymarch(h, 24, rd, t))
|
||||
{
|
||||
float3 p = h.world + t * rd;
|
||||
d = length(p - _c._e.xyz) / 500;
|
||||
return exp(80 * d);
|
||||
}
|
||||
discard;
|
||||
return 0;
|
||||
}
|
||||
|
||||
float log_conv(float x0, float X, float y0, float Y)
|
||||
{
|
||||
return X + log(x0 + (y0 * exp(Y - X)));
|
||||
}
|
||||
|
||||
float blur(float2 uv, float2 dirAndSize)
|
||||
{
|
||||
const float coeff[7] = { 0.006, 0.061, 0.242, 0.382, 0.242, 0.061, 0.006 };
|
||||
float2 s = uv - 3 * dirAndSize.xy;
|
||||
float accum = 0;
|
||||
for (int i = 0; i < 7; ++i)
|
||||
accum += t2d4.Sample(s0, s + i * dirAndSize.xy).x * coeff[i];
|
||||
return accum;
|
||||
}
|
||||
|
||||
//[entrypoint(ps)]
|
||||
float ps_BlurH(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
float w,h;
|
||||
t2d4.GetDimensions(w, h);
|
||||
return blur(uv, float2(1/w,0));
|
||||
}
|
||||
|
||||
//[entrypoint(ps)]
|
||||
float ps_BlurV(in float2 uv : TEXCOORD) : SV_Target0
|
||||
{
|
||||
float w,h;
|
||||
t2d4.GetDimensions(w, h);
|
||||
return blur(uv, float2(0,1/h));
|
||||
}
|
||||
27
aquarium/src/intro/shaders/structs.hlsl
Normal file
27
aquarium/src/intro/shaders/structs.hlsl
Normal file
@@ -0,0 +1,27 @@
|
||||
//[syncstruct(audio)]
|
||||
struct Sync
|
||||
{
|
||||
float time;
|
||||
float3 cameraPos;
|
||||
float dummy1;
|
||||
float3 cameraAt;
|
||||
float dummy2;
|
||||
float3 cameraUp;
|
||||
};
|
||||
|
||||
struct Hull
|
||||
{
|
||||
float3 position : c;
|
||||
int type : t;
|
||||
sample float3 world : w;
|
||||
float3 scale : s;
|
||||
sample float4 o : SV_Position;
|
||||
float3x3 rotate : r;
|
||||
};
|
||||
|
||||
struct Cam
|
||||
{
|
||||
float4 _d : d;
|
||||
float4 _e : e;
|
||||
float4 _u : u;
|
||||
};
|
||||
90
aquarium/src/intro/shaders/textures.hlsl
Normal file
90
aquarium/src/intro/shaders/textures.hlsl
Normal file
@@ -0,0 +1,90 @@
|
||||
static const float
|
||||
f = 0.0535,
|
||||
k = 0.062,
|
||||
PI = acos(-1),
|
||||
TAU = 2 * PI;
|
||||
|
||||
static const float3x3 conv = float3x3(.05, .2, 0.05, .2, -1, .2, .05, .2, .05);
|
||||
|
||||
float voronoi(float2 p)
|
||||
{
|
||||
float2 g = floor(p), o; p -= g;
|
||||
float3 d = 1;
|
||||
|
||||
for (int y = -1; y <= 1; y++)
|
||||
for (int x = -1; x <= 1; x++)
|
||||
o = float2(x, y),
|
||||
o += hash22(g + o) - p,
|
||||
d.z = dot(o, o),
|
||||
d.y = max(d.x, min(d.y, d.z)),
|
||||
d.x = min(d.x, d.z);
|
||||
|
||||
return d.y - d.x;
|
||||
}
|
||||
|
||||
//[entrypoint(cs)]
|
||||
[numthreads(16, 16, 1)] void cs_Stone(uint3 i : SV_DispatchThreadID)
|
||||
{
|
||||
float2 dim;
|
||||
o2d0.GetDimensions(dim.x, dim.y);
|
||||
float2 p = i.xy / dim;
|
||||
float c =
|
||||
voronoi(p * 5. - .35) * .6 +
|
||||
voronoi((p.yx + .5) * 10.) * .3 +
|
||||
(1. - voronoi(p * 25.)) * .075 +
|
||||
voronoi(p * 60.) * .025;
|
||||
|
||||
float4 col = t2d0[i.xy];
|
||||
col.z = c;
|
||||
o2d0[i.xy] = col;
|
||||
}
|
||||
|
||||
float2 fab(int2 uv)
|
||||
{
|
||||
float dim = 2048.;
|
||||
uv = mod2(uv, dim);
|
||||
float2 ab = t2d0[uv].xy;
|
||||
return float2(ab.x, max(ab.y, 0.25*step(0.98, hash12(uv / dim))));
|
||||
}
|
||||
|
||||
float2 Laplace(int2 uv)
|
||||
{
|
||||
float2 result = float2(0, 0);
|
||||
|
||||
for (int y = -1; y <= 1; y++)
|
||||
for (int x = -1; x <= 1; x++)
|
||||
result += fab(uv + int2(x, y)) * conv[x + 1][y + 1];
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
//[entrypoint(cs)]
|
||||
[numthreads(16, 16, 1)] void cs_Coral(uint3 i : SV_DispatchThreadID)
|
||||
{
|
||||
float2 ab = fab(i.xy), Lab = Laplace(i.xy);
|
||||
float ab2 = ab.x * ab.y * ab.y;
|
||||
ab.x += Lab.x - ab2 + f * (1.0 - ab.x);
|
||||
ab.y += .5 * Lab.y + ab2 - (k + f) * ab.y;
|
||||
float4 col = t2d0[i.xy];
|
||||
col.xy = ab;
|
||||
o2d0[i.xy] = col;
|
||||
}
|
||||
|
||||
//[entrypoint(cs)]
|
||||
[numthreads(16, 16, 1)] void cs_Caustics(uint3 i : SV_DispatchThreadID)
|
||||
{
|
||||
float2 dim;
|
||||
o2d0.GetDimensions(dim.x, dim.y);
|
||||
float d = 1315., c = 1., n = 1., t;
|
||||
for (float2 uv = i.xy / dim, p = mod2(uv*TAU, TAU) - d, z = float2(p); n <= 5.; n++)
|
||||
t = _s.time * (30. - (1.5 / n)),
|
||||
z = p + float2(cos(t - z.x) + sin(t + z.y),
|
||||
sin(t - z.y) + cos(t + z.x)),
|
||||
c += d / length(float2(p.x / sin(t + z.x),
|
||||
p.y / cos(t + z.y)));
|
||||
c = pow(1. - c / n, 4.);
|
||||
|
||||
float4 col = t2d0[i.xy];
|
||||
col.w = c;
|
||||
o2d0[i.xy] = col;
|
||||
}
|
||||
BIN
aquarium/src/music/aquarium-rev.4kp
Normal file
BIN
aquarium/src/music/aquarium-rev.4kp
Normal file
Binary file not shown.
BIN
aquarium/src/music/aquarium.it
Normal file
BIN
aquarium/src/music/aquarium.it
Normal file
Binary file not shown.
BIN
aquarium/src/music/aquarium8k-rev.4kp
Normal file
BIN
aquarium/src/music/aquarium8k-rev.4kp
Normal file
Binary file not shown.
BIN
aquarium/src/music/choir.4ki
Normal file
BIN
aquarium/src/music/choir.4ki
Normal file
Binary file not shown.
BIN
aquarium/src/music/fm.4ki
Normal file
BIN
aquarium/src/music/fm.4ki
Normal file
Binary file not shown.
BIN
aquarium/src/music/global.4ki
Normal file
BIN
aquarium/src/music/global.4ki
Normal file
Binary file not shown.
6
aquarium/src/shc/App.config
Normal file
6
aquarium/src/shc/App.config
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8"/>
|
||||
</startup>
|
||||
</configuration>
|
||||
610
aquarium/src/shc/Program.cs
Normal file
610
aquarium/src/shc/Program.cs
Normal file
@@ -0,0 +1,610 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace shc
|
||||
{
|
||||
class Program
|
||||
{
|
||||
struct EntryPoint
|
||||
{
|
||||
public string TypeName { get; set; }
|
||||
public string Name { get; set; }
|
||||
public string Prefix { get; set; }
|
||||
public string[] Parameters { get; set; }
|
||||
}
|
||||
|
||||
struct ShaderInfo
|
||||
{
|
||||
public ShaderInfo(string pointerType, string prefix, string createFunction)
|
||||
: this()
|
||||
{
|
||||
PointerType = pointerType;
|
||||
Prefix = prefix;
|
||||
CreateFunction = createFunction;
|
||||
}
|
||||
|
||||
public string PointerType { get; set; }
|
||||
public string Prefix { get; set; }
|
||||
public string CreateFunction { get; set; }
|
||||
}
|
||||
|
||||
static int Main(string[] args)
|
||||
{
|
||||
Console.WriteLine("shc " + string.Join(" ", args.Select(arg => "\"" + arg + "\"")));
|
||||
|
||||
if (args.Length != 5)
|
||||
{
|
||||
Console.WriteLine("Usage: shc $(HlslInputPath) $(MinifiedHeaderPath) $(ShaderHeaderPath) $(MergedHlslOutputPath) $(SyncMetaPath)");
|
||||
return -1;
|
||||
}
|
||||
|
||||
var path = Path.GetFullPath(args[0]);
|
||||
if (!File.Exists(args[0]))
|
||||
{
|
||||
Console.WriteLine("ERROR: " + args[0] + " does not exist!");
|
||||
return -2;
|
||||
}
|
||||
|
||||
var resultLines = new List<Tuple<string, string>>();
|
||||
var entryPoints = new List<EntryPoint>();
|
||||
string mergedPath = args[3];
|
||||
string metaPath = args[4];
|
||||
string mergedMetaPath = mergedPath + ".meta";
|
||||
try
|
||||
{
|
||||
GetCombinedLinesFromIncludes(path, resultLines, entryPoints);
|
||||
resultLines.Add(Tuple.Create(string.Empty, string.Empty));
|
||||
File.WriteAllText(mergedPath, string.Join("\n", resultLines.Select(l => l.Item1)));
|
||||
File.WriteAllText(mergedMetaPath, string.Join("\n", resultLines.Select(l => l.Item2)));
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Console.WriteLine("ERROR: While loading " + path + ": " + e.Message);
|
||||
return -3;
|
||||
}
|
||||
|
||||
var outputPath = Path.GetFullPath(args[1]);
|
||||
if (File.Exists(outputPath))
|
||||
{
|
||||
File.Delete(outputPath);
|
||||
}
|
||||
var outputDir = Path.GetDirectoryName(outputPath);
|
||||
if (!Directory.Exists(outputDir))
|
||||
{
|
||||
Directory.CreateDirectory(outputDir);
|
||||
}
|
||||
|
||||
var toolsLocation = Path.Combine(Path.GetDirectoryName(System.Reflection.Assembly.GetEntryAssembly().Location), "..\\tools");
|
||||
try
|
||||
{
|
||||
string arguments = "--hlsl -v -o " + outputPath + " ";
|
||||
if (entryPoints.Count > 0)
|
||||
{
|
||||
arguments += "--no-renaming-list " + string.Join(",", entryPoints.Select(kvp => kvp.Name)) + " ";
|
||||
//arguments += "--no-renaming --no-sequence ";
|
||||
}
|
||||
arguments += mergedPath;
|
||||
|
||||
Process myProcess = new Process();
|
||||
ProcessStartInfo myProcessStartInfo = new ProcessStartInfo(Path.Combine(toolsLocation, "shader_minifier.exe"), arguments);
|
||||
myProcessStartInfo.UseShellExecute = false;
|
||||
myProcessStartInfo.RedirectStandardOutput = true;
|
||||
myProcess.StartInfo = myProcessStartInfo;
|
||||
myProcess.Start();
|
||||
StreamReader myStreamReader = myProcess.StandardOutput;
|
||||
var output = myStreamReader.ReadToEnd();
|
||||
Console.WriteLine(output);
|
||||
myProcess.WaitForExit();
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Console.WriteLine("ERROR: While running shader minifier: " + e.Message);
|
||||
return -4;
|
||||
}
|
||||
|
||||
if (!File.Exists(outputPath))
|
||||
{
|
||||
return -5;
|
||||
}
|
||||
|
||||
var outputLines = File.ReadAllLines(outputPath).ToArray();
|
||||
int iNumThreadCount = 0;
|
||||
for (int i = 0; i < outputLines.Length; ++i)
|
||||
{
|
||||
if (outputLines[i].Trim() == "\"[numthreads(16,16,1)]\"")
|
||||
{
|
||||
++iNumThreadCount;
|
||||
}
|
||||
}
|
||||
if (iNumThreadCount > 1)
|
||||
{
|
||||
for (int i = 0; i < outputLines.Length; ++i)
|
||||
{
|
||||
if (outputLines[i].Trim() == "char merged_hlsl[] =")
|
||||
{
|
||||
outputLines[i] = "char merged_hlsl[] = \"#define _ [numthreads(16,16,1)]\\n\"";
|
||||
}
|
||||
else if (outputLines[i].Trim() == "\"[numthreads(16,16,1)]\"")
|
||||
{
|
||||
outputLines[i] = " \"_ \"";
|
||||
}
|
||||
}
|
||||
}
|
||||
File.WriteAllLines(outputPath, outputLines);
|
||||
|
||||
try
|
||||
{
|
||||
var headerPath = Path.GetFullPath(args[2]);
|
||||
using (var stream = new FileStream(headerPath, FileMode.Create, FileAccess.Write))
|
||||
{
|
||||
using (var writer = new StreamWriter(stream))
|
||||
{
|
||||
if (entryPoints.Count > 0)
|
||||
{
|
||||
writer.WriteLine("#pragma once");
|
||||
writer.WriteLine("// WARNING: This file is autogenerated by shc. Do not edit");
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma data_seg(\".cs_5_0\")");
|
||||
writer.WriteLine("static char cs_5_0[] = \"cs_5_0\";");
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma data_seg(\".vs_5_0\")");
|
||||
writer.WriteLine("static char vs_5_0[] = \"vs_5_0\";");
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma data_seg(\".gs_5_0\")");
|
||||
writer.WriteLine("static char gs_5_0[] = \"gs_5_0\";");
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma data_seg(\".ds_5_0\")");
|
||||
writer.WriteLine("static char ds_5_0[] = \"ds_5_0\";");
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma data_seg(\".hs_5_0\")");
|
||||
writer.WriteLine("static char hs_5_0[] = \"hs_5_0\";");
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma data_seg(\".ps_5_0\")");
|
||||
writer.WriteLine("static char ps_5_0[] = \"ps_5_0\";");
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma bss_seg(\".shaderbss\")");
|
||||
foreach (var entryPoint in entryPoints)
|
||||
{
|
||||
if (entryPoint.TypeName == "hc")
|
||||
continue;
|
||||
|
||||
foreach (var shaderInfo in GetShaderInfo(entryPoint.TypeName))
|
||||
{
|
||||
writer.WriteLine("static " + shaderInfo.PointerType + "* " + shaderInfo.Prefix + entryPoint.Name + ";");
|
||||
}
|
||||
}
|
||||
|
||||
foreach (var entryPoint in entryPoints)
|
||||
{
|
||||
if (entryPoint.TypeName == "hc")
|
||||
continue;
|
||||
|
||||
if (entryPoint.TypeName == "gs_so" || entryPoint.TypeName == "vs_gs_so")
|
||||
{
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma data_seg(\"." + entryPoint.Name + "SODeclarations\")");
|
||||
writer.WriteLine("extern D3D11_SO_DECLARATION_ENTRY " + entryPoint.Name + "SODeclarations[" + entryPoint.Parameters[0] + "];");
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma data_seg(\"." + entryPoint.Name + "Strides\")");
|
||||
writer.WriteLine("extern UINT " + entryPoint.Name + "Strides[" + entryPoint.Parameters[1] + "];");
|
||||
}
|
||||
|
||||
if (entryPoint.TypeName == "vs_il")
|
||||
{
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma data_seg(\"." + entryPoint.Name + "InputLayoutDesc\")");
|
||||
writer.WriteLine("extern D3D11_INPUT_ELEMENT_DESC " + entryPoint.Name + "InputLayoutDesc[" + entryPoint.Parameters[0] + "];");
|
||||
}
|
||||
}
|
||||
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#pragma code_seg(\".FrameworkShadersCompile\")");
|
||||
writer.WriteLine("INLINE void FrameworkShadersCompile()");
|
||||
writer.WriteLine("{");
|
||||
foreach (var entryPoint in entryPoints)
|
||||
{
|
||||
if (entryPoint.TypeName == "hc")
|
||||
continue;
|
||||
|
||||
writer.WriteLine("\tCompileShader(\"" + entryPoint.Name + "\", " + entryPoint.Prefix + "_5_0);");
|
||||
foreach (var shaderInfo in GetShaderInfo(entryPoint.TypeName))
|
||||
{
|
||||
if (shaderInfo.CreateFunction == "CreateGeometryShaderWithStreamOutput")
|
||||
{
|
||||
var parameters = string.Join(", ", entryPoint.Parameters);
|
||||
writer.WriteLine("\tdevice->CreateGeometryShaderWithStreamOutput(shaderCode, shaderSize, " + entryPoint.Name + "SODeclarations, " + entryPoint.Parameters[0] + ", " + entryPoint.Name + "Strides, " + entryPoint.Parameters[1] + ", D3D11_SO_NO_RASTERIZED_STREAM, NULL, &" + shaderInfo.Prefix + entryPoint.Name + ");");
|
||||
}
|
||||
else if (shaderInfo.CreateFunction == "CreateInputLayout")
|
||||
{
|
||||
var parameters = string.Join(", ", entryPoint.Parameters);
|
||||
writer.WriteLine("\tdevice->CreateInputLayout(" + entryPoint.Name + "InputLayoutDesc, " + entryPoint.Parameters[0] + ", shaderCode, shaderSize, &" + shaderInfo.Prefix + entryPoint.Name + ");");
|
||||
}
|
||||
else
|
||||
{
|
||||
writer.WriteLine("\tdevice->" + shaderInfo.CreateFunction + "(shaderCode, shaderSize, NULL, &" + shaderInfo.Prefix + entryPoint.Name + ");");
|
||||
}
|
||||
}
|
||||
}
|
||||
writer.WriteLine("}");
|
||||
writer.WriteLine();
|
||||
}
|
||||
|
||||
if (s_dSyncStructLines.Count > 0)
|
||||
{
|
||||
writer.WriteLine("#ifndef AUTHORING");
|
||||
writer.WriteLine("#include \"syncdata.g.h\"");
|
||||
writer.WriteLine("#endif");
|
||||
|
||||
int iSize = 0;
|
||||
var syncVariables = new List<string>();
|
||||
foreach (var syncType in s_dSyncStructLines.OrderBy(k => k.Key == "audio" ? "" : k.Key))
|
||||
{
|
||||
List<Tuple<int, string>> lSyncVariables = new List<Tuple<int, string>>();
|
||||
var sSyncType = syncType.Key;
|
||||
foreach (var line in syncType.Value)
|
||||
{
|
||||
var tokens = line.Split(' ', '\t', ';').Select(t => t.Trim()).Where(t => !string.IsNullOrEmpty(t)).ToList();
|
||||
if (tokens[0] == "struct")
|
||||
{
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("struct SyncStruct_" + sSyncType);
|
||||
continue;
|
||||
}
|
||||
|
||||
int typeIndex = Math.Max(Math.Max(Math.Max(Math.Max(Math.Max(Math.Max(tokens.IndexOf("float"), tokens.IndexOf("float2")), tokens.IndexOf("float3")), tokens.IndexOf("float4")), tokens.IndexOf("float4x4")), tokens.IndexOf("int")), tokens.IndexOf("uint"));
|
||||
if (typeIndex != -1)
|
||||
{
|
||||
switch (tokens[typeIndex])
|
||||
{
|
||||
case "float":
|
||||
{
|
||||
lSyncVariables.Add(new Tuple<int, string>(1, tokens[typeIndex + 1]));
|
||||
iSize += 4;
|
||||
break;
|
||||
}
|
||||
case "float2":
|
||||
{
|
||||
lSyncVariables.Add(new Tuple<int, string>(2, tokens[typeIndex + 1]));
|
||||
iSize += 8;
|
||||
break;
|
||||
}
|
||||
case "float3":
|
||||
{
|
||||
lSyncVariables.Add(new Tuple<int, string>(3, tokens[typeIndex + 1]));
|
||||
iSize += 12;
|
||||
break;
|
||||
}
|
||||
case "float4":
|
||||
{
|
||||
lSyncVariables.Add(new Tuple<int, string>(4, tokens[typeIndex + 1]));
|
||||
iSize += 16;
|
||||
break;
|
||||
}
|
||||
case "float4x4":
|
||||
{
|
||||
lSyncVariables.Add(new Tuple<int, string>(5, tokens[typeIndex + 1]));
|
||||
iSize += 64;
|
||||
break;
|
||||
}
|
||||
case "int":
|
||||
{
|
||||
lSyncVariables.Add(new Tuple<int, string>(6, tokens[typeIndex + 1]));
|
||||
iSize += 4;
|
||||
break;
|
||||
}
|
||||
case "uint":
|
||||
{
|
||||
lSyncVariables.Add(new Tuple<int, string>(7, tokens[typeIndex + 1]));
|
||||
iSize += 4;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (line.Trim()[0] == '}')
|
||||
{
|
||||
if (iSize % 16 != 0)
|
||||
iSize += 16 - (iSize % 16);
|
||||
|
||||
foreach (var syncVar in lSyncVariables)
|
||||
{
|
||||
switch (syncVar.Item1)
|
||||
{
|
||||
case 1:
|
||||
syncVariables.Add(syncVar.Item2);
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + ";");
|
||||
iSize -= 4;
|
||||
break;
|
||||
case 2:
|
||||
syncVariables.Add(syncVar.Item2 + "_x");
|
||||
syncVariables.Add(syncVar.Item2 + "_y");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_x;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_y;");
|
||||
iSize -= 8;
|
||||
break;
|
||||
case 3:
|
||||
syncVariables.Add(syncVar.Item2 + "_x");
|
||||
syncVariables.Add(syncVar.Item2 + "_y");
|
||||
syncVariables.Add(syncVar.Item2 + "_z");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_x;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_y;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_z;");
|
||||
iSize -= 12;
|
||||
break;
|
||||
case 4:
|
||||
syncVariables.Add(syncVar.Item2 + "_x");
|
||||
syncVariables.Add(syncVar.Item2 + "_y");
|
||||
syncVariables.Add(syncVar.Item2 + "_z");
|
||||
syncVariables.Add(syncVar.Item2 + "_w");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_x;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_y;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_z;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_w;");
|
||||
iSize -= 16;
|
||||
break;
|
||||
case 5:
|
||||
syncVariables.Add(syncVar.Item2 + "_xx");
|
||||
syncVariables.Add(syncVar.Item2 + "_xy");
|
||||
syncVariables.Add(syncVar.Item2 + "_xz");
|
||||
syncVariables.Add(syncVar.Item2 + "_xw");
|
||||
syncVariables.Add(syncVar.Item2 + "_yx");
|
||||
syncVariables.Add(syncVar.Item2 + "_yy");
|
||||
syncVariables.Add(syncVar.Item2 + "_yz");
|
||||
syncVariables.Add(syncVar.Item2 + "_yw");
|
||||
syncVariables.Add(syncVar.Item2 + "_zx");
|
||||
syncVariables.Add(syncVar.Item2 + "_zy");
|
||||
syncVariables.Add(syncVar.Item2 + "_zz");
|
||||
syncVariables.Add(syncVar.Item2 + "_zw");
|
||||
syncVariables.Add(syncVar.Item2 + "_wx");
|
||||
syncVariables.Add(syncVar.Item2 + "_wy");
|
||||
syncVariables.Add(syncVar.Item2 + "_wz");
|
||||
syncVariables.Add(syncVar.Item2 + "_ww");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_xx;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_xy;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_xz;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_xw;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_yx;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_yy;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_yz;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_yw;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_zx;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_zy;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_zz;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_zw;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_wx;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_wy;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_wz;");
|
||||
writer.WriteLine("\tfloat " + syncVar.Item2 + "_ww;");
|
||||
iSize -= 64;
|
||||
break;
|
||||
case 6:
|
||||
syncVariables.Add(syncVar.Item2);
|
||||
writer.WriteLine("\tint " + syncVar.Item2 + ";");
|
||||
iSize -= 4;
|
||||
break;
|
||||
case 7:
|
||||
syncVariables.Add(syncVar.Item2);
|
||||
writer.WriteLine("\tunsigned int " + syncVar.Item2 + ";");
|
||||
iSize -= 4;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
int iDummyIndex = 1;
|
||||
|
||||
while (iSize > 0)
|
||||
{
|
||||
writer.WriteLine("\tfloat dummy_" + iDummyIndex++ + ";");
|
||||
iSize -= 4;
|
||||
}
|
||||
writer.WriteLine(line);
|
||||
}
|
||||
else
|
||||
{
|
||||
writer.WriteLine(line);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
File.WriteAllText(metaPath, string.Join("\n", syncVariables));
|
||||
writer.WriteLine();
|
||||
writer.WriteLine("#define SYNC");
|
||||
writer.WriteLine("#include \"../sync.h\"");
|
||||
writer.WriteLine();
|
||||
}
|
||||
|
||||
writer.Flush();
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Console.WriteLine("ERROR: While generating shc output: " + e.Message);
|
||||
return -6;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
private static IEnumerable<ShaderInfo> GetShaderInfo(string p)
|
||||
{
|
||||
if (p == "cs")
|
||||
yield return new ShaderInfo("ID3D11ComputeShader", "", "CreateComputeShader");
|
||||
else if (p == "vs")
|
||||
yield return new ShaderInfo("ID3D11VertexShader", "", "CreateVertexShader");
|
||||
else if (p == "vs_il")
|
||||
{
|
||||
yield return new ShaderInfo("ID3D11VertexShader", "vs_", "CreateVertexShader");
|
||||
yield return new ShaderInfo("ID3D11InputLayout", "il_", "CreateInputLayout");
|
||||
}
|
||||
else if (p == "ds")
|
||||
yield return new ShaderInfo("ID3D11DomainShader", "", "CreateDomainShader");
|
||||
else if (p == "hs")
|
||||
yield return new ShaderInfo("ID3D11HullShader", "", "CreateHullShader");
|
||||
else if (p == "gs")
|
||||
yield return new ShaderInfo("ID3D11GeometryShader", "", "CreateGeometryShader");
|
||||
else if (p == "ps")
|
||||
yield return new ShaderInfo("ID3D11PixelShader", "", "CreatePixelShader");
|
||||
else if (p == "gs_so")
|
||||
yield return new ShaderInfo("ID3D11GeometryShader", "", "CreateGeometryShaderWithStreamOutput");
|
||||
else if (p == "vs_gs_so")
|
||||
{
|
||||
yield return new ShaderInfo("ID3D11VertexShader", "vs_", "CreateVertexShader");
|
||||
yield return new ShaderInfo("ID3D11GeometryShader", "gs_", "CreateGeometryShaderWithStreamOutput");
|
||||
}
|
||||
}
|
||||
|
||||
private static void GetCombinedLinesFromIncludes(string path, List<Tuple<string, string>> resultLines, List<EntryPoint> entryPoints)
|
||||
{
|
||||
var loadedPaths = new List<string>();
|
||||
AggregateLines(path, resultLines, entryPoints, loadedPaths);
|
||||
}
|
||||
|
||||
private static void AggregateLines(string path, List<Tuple<string, string>> resultLines, List<EntryPoint> entryPoints, List<string> loadedPaths)
|
||||
{
|
||||
if (loadedPaths.Contains(path))
|
||||
return;
|
||||
|
||||
loadedPaths.Add(path);
|
||||
var basePath = Path.GetDirectoryName(path);
|
||||
var lines = File.ReadAllLines(path);
|
||||
string sEntryPointType = null;
|
||||
string[] entryPointParameters = null;
|
||||
int lineNumber = 1;
|
||||
var enumerator = lines.GetEnumerator();
|
||||
while (enumerator.MoveNext())
|
||||
{
|
||||
var line = (string)enumerator.Current;
|
||||
if (line.StartsWith("#include"))
|
||||
{
|
||||
var includeFile = line.Substring(8).Trim().Split('"')[1];
|
||||
var includePath = Path.GetFullPath(Path.Combine(basePath, includeFile));
|
||||
AggregateLines(includePath, resultLines, entryPoints, loadedPaths);
|
||||
}
|
||||
else if (line.Trim().StartsWith("//[entrypoint"))
|
||||
{
|
||||
sEntryPointType = line.Trim().Substring(13).Trim();
|
||||
if (sEntryPointType.StartsWith("("))
|
||||
{
|
||||
entryPointParameters = sEntryPointType.Substring(1, sEntryPointType.Length - 2).Trim().Split(',', ')').Skip(1).ToArray();
|
||||
entryPointParameters = entryPointParameters.Take(entryPointParameters.Length - 1).Select(p => p.Trim()).ToArray();
|
||||
sEntryPointType = sEntryPointType.Substring(1).Split(',', ')')[0];
|
||||
}
|
||||
else
|
||||
{
|
||||
sEntryPointType = "unknown";
|
||||
}
|
||||
|
||||
if (sEntryPointType == "vs_gs_so" || sEntryPointType == "gs_so")
|
||||
{
|
||||
if (entryPointParameters.Length != 2)
|
||||
{
|
||||
throw new Exception("An entry point of type " + sEntryPointType + " needs 2 parameters: (StreamOutputDeclaration count, Stride count)");
|
||||
}
|
||||
}
|
||||
else if (sEntryPointType == "vs_il")
|
||||
{
|
||||
if (entryPointParameters.Length != 1)
|
||||
{
|
||||
throw new Exception("An entry point of type " + sEntryPointType + " needs 1 parameter: (InputElementDesc count)");
|
||||
}
|
||||
}
|
||||
else if (entryPointParameters != null && entryPointParameters.Length != 0)
|
||||
{
|
||||
throw new Exception("An entry point of type " + sEntryPointType + " needs no parameters");
|
||||
}
|
||||
|
||||
resultLines.Add(Tuple.Create(string.Empty, $"{path}|{lineNumber}"));
|
||||
}
|
||||
else if (line.Trim().StartsWith("[patchconstantfunc"))
|
||||
{
|
||||
var sEntryPointName = line.Trim().Substring(18).Trim();
|
||||
if (sEntryPointName.StartsWith("("))
|
||||
{
|
||||
sEntryPointName = sEntryPointName.Substring(2).Split('\"', ')')[0];
|
||||
}
|
||||
entryPoints.Add(new EntryPoint() { TypeName = "hc", Name = sEntryPointName });
|
||||
resultLines.Add(Tuple.Create(line, $"{path}|{lineNumber}"));
|
||||
}
|
||||
else if (line.Trim().StartsWith("//[syncstruct"))
|
||||
{
|
||||
var sSyncType = line.Trim().Substring(13).Trim();
|
||||
if (sSyncType.StartsWith("("))
|
||||
{
|
||||
sSyncType = sSyncType.Substring(1, sSyncType.Length - 3).Trim();
|
||||
}
|
||||
else
|
||||
{
|
||||
throw new Exception("//[syncstruct(type)] missing type argument. Specify audio.");
|
||||
}
|
||||
if (sSyncType != "audio")
|
||||
{
|
||||
throw new Exception("//[syncstruct(type)] invalid type argument. Specify audio.");
|
||||
}
|
||||
|
||||
int iBracketCount = 0;
|
||||
bool bStructStarted = false;
|
||||
bool bStructFound = false;
|
||||
var list = s_dSyncStructLines[sSyncType] = new List<string>();
|
||||
while (enumerator.MoveNext())
|
||||
{
|
||||
line = (string)enumerator.Current;
|
||||
if (line.Contains('{'))
|
||||
{
|
||||
++iBracketCount;
|
||||
bStructStarted = true;
|
||||
}
|
||||
if (line.Contains('}'))
|
||||
{
|
||||
--iBracketCount;
|
||||
}
|
||||
|
||||
resultLines.Add(Tuple.Create(line, $"{path}|{lineNumber}"));
|
||||
list.Add(line);
|
||||
++lineNumber;
|
||||
|
||||
if (bStructStarted && iBracketCount == 0)
|
||||
{
|
||||
bStructFound = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!bStructFound)
|
||||
{
|
||||
throw new Exception("[syncstruct(type)] may only be used before a struct");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (sEntryPointType != null)
|
||||
{
|
||||
var tempLine = line.Trim();
|
||||
while (tempLine.StartsWith("["))
|
||||
{
|
||||
var idx = tempLine.IndexOf("]");
|
||||
tempLine = tempLine.Substring(idx + 1).Trim();
|
||||
}
|
||||
var functionName = tempLine.Split(' ')[1].Split('(')[0];
|
||||
entryPoints.Add(new EntryPoint() { TypeName = sEntryPointType.ToLower(), Name = functionName, Prefix = sEntryPointType.ToLower().Substring(0, 2), Parameters = entryPointParameters });
|
||||
sEntryPointType = null;
|
||||
}
|
||||
|
||||
var resultLine = line;
|
||||
var commentIndex = line.IndexOf("//");
|
||||
if (commentIndex != -1)
|
||||
resultLine = resultLine.Substring(0, commentIndex);
|
||||
|
||||
resultLines.Add(Tuple.Create(resultLine, $"{path}|{lineNumber}"));
|
||||
}
|
||||
|
||||
++lineNumber;
|
||||
}
|
||||
}
|
||||
|
||||
private static Dictionary<string, List<string>> s_dSyncStructLines = new Dictionary<string, List<string>>();
|
||||
}
|
||||
}
|
||||
36
aquarium/src/shc/Properties/AssemblyInfo.cs
Normal file
36
aquarium/src/shc/Properties/AssemblyInfo.cs
Normal file
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("shc")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("shc")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2014")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("8e619b64-e97a-4b10-8e79-96582ebfe084")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||
@@ -0,0 +1,4 @@
|
||||
// <autogenerated />
|
||||
using System;
|
||||
using System.Reflection;
|
||||
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
|
||||
1
aquarium/src/shc/obj/Debug/CoreCompileInputs.cache
Normal file
1
aquarium/src/shc/obj/Debug/CoreCompileInputs.cache
Normal file
@@ -0,0 +1 @@
|
||||
74b695782a65c8a70ffbb698472c89ba545b7a8f
|
||||
Binary file not shown.
BIN
aquarium/src/shc/obj/Debug/shc.csproj.AssemblyReference.cache
Normal file
BIN
aquarium/src/shc/obj/Debug/shc.csproj.AssemblyReference.cache
Normal file
Binary file not shown.
@@ -0,0 +1 @@
|
||||
53b94c6b113657291977aed26ce7381399de840f
|
||||
18
aquarium/src/shc/obj/Debug/shc.csproj.FileListAbsolute.txt
Normal file
18
aquarium/src/shc/obj/Debug/shc.csproj.FileListAbsolute.txt
Normal file
@@ -0,0 +1,18 @@
|
||||
E:\alcatraz\8kode\bin\shc.exe.config
|
||||
E:\alcatraz\8kode\bin\shc.exe
|
||||
E:\alcatraz\8kode\bin\shc.pdb
|
||||
E:\alcatraz\8kode\src\shc\obj\Debug\shc.exe
|
||||
E:\alcatraz\8kode\src\shc\obj\Debug\shc.pdb
|
||||
E:\alcatraz\aquarium\bin\shc.exe.config
|
||||
E:\alcatraz\aquarium\bin\shc.exe
|
||||
E:\alcatraz\aquarium\bin\shc.pdb
|
||||
E:\alcatraz\aquarium\src\shc\obj\Debug\shc.exe
|
||||
E:\alcatraz\aquarium\src\shc\obj\Debug\shc.pdb
|
||||
E:\blu-flame.org\aquarium\bin\shc.exe.config
|
||||
E:\blu-flame.org\aquarium\bin\shc.exe
|
||||
E:\blu-flame.org\aquarium\bin\shc.pdb
|
||||
E:\blu-flame.org\aquarium\src\shc\obj\Debug\shc.csproj.AssemblyReference.cache
|
||||
E:\blu-flame.org\aquarium\src\shc\obj\Debug\shc.csproj.SuggestedBindingRedirects.cache
|
||||
E:\blu-flame.org\aquarium\src\shc\obj\Debug\shc.csproj.CoreCompileInputs.cache
|
||||
E:\blu-flame.org\aquarium\src\shc\obj\Debug\shc.exe
|
||||
E:\blu-flame.org\aquarium\src\shc\obj\Debug\shc.pdb
|
||||
BIN
aquarium/src/shc/obj/Debug/shc.exe
Normal file
BIN
aquarium/src/shc/obj/Debug/shc.exe
Normal file
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user