Split backend/common in backend/ and common/

This directory used to contain both the state tracking code for the
backends, and the common utilities that could be used both by the
backends and the rest of the code. Things are now:

 - src/common is utility code for the whole repo
 - src/backend contains libNXT's code
 - src/utils is utility code that we don't want in libNXT

This commit also changes all includes to use global paths from src/
bacause it had to touch a bunch of #include statements anyway.
This commit is contained in:
Corentin Wallez 2017-07-06 14:41:13 -04:00 committed by Corentin Wallez
parent a9b2a9871c
commit fffe6dfa16
161 changed files with 673 additions and 599 deletions

View File

@ -77,6 +77,7 @@ SetCXX14(mock_nxt)
set(SRC_DIR ${CMAKE_CURRENT_SOURCE_DIR}/src)
add_subdirectory(src/common)
add_subdirectory(src/backend)
add_subdirectory(src/wire)
add_subdirectory(src/utils)

View File

@ -15,7 +15,7 @@
#include "nxt/nxt.h"
#include "nxt/nxtcpp.h"
#include "{{namespace}}/GeneratedCodeIncludes.h"
#include "backend/{{namespace}}/GeneratedCodeIncludes.h"
namespace backend {
namespace {{namespace}} {

View File

@ -12,8 +12,8 @@
//* See the License for the specific language governing permissions and
//* limitations under the License.
#include "Wire.h"
#include "WireCmd.h"
#include "wire/Wire.h"
#include "wire/WireCmd.h"
#include <cassert>
#include <cstring>

View File

@ -12,8 +12,8 @@
//* See the License for the specific language governing permissions and
//* limitations under the License.
#include "Wire.h"
#include "WireCmd.h"
#include "wire/Wire.h"
#include "wire/WireCmd.h"
#include <cassert>
#include <cstring>

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "BindGroup.h"
#include "backend/BindGroup.h"
#include "BindGroupLayout.h"
#include "Buffer.h"
#include "Device.h"
#include "Texture.h"
#include "backend/BindGroupLayout.h"
#include "backend/Buffer.h"
#include "backend/Device.h"
#include "backend/Texture.h"
namespace backend {

View File

@ -12,12 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_BINDGROUP_H_
#define BACKEND_COMMON_BINDGROUP_H_
#ifndef BACKEND_BINDGROUP_H_
#define BACKEND_BINDGROUP_H_
#include "Forward.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/Builder.h"
#include "backend/Forward.h"
#include "backend/RefCounted.h"
#include "common/Constants.h"
#include "nxt/nxtcpp.h"
@ -89,4 +90,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_BINDGROUP_H_
#endif // BACKEND_BINDGROUP_H_

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "BindGroupLayout.h"
#include "backend/BindGroupLayout.h"
#include "Device.h"
#include "backend/Device.h"
#include <functional>

View File

@ -12,12 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_BINDGROUPLAYOUT_H_
#define BACKEND_COMMON_BINDGROUPLAYOUT_H_
#ifndef BACKEND_BINDGROUPLAYOUT_H_
#define BACKEND_BINDGROUPLAYOUT_H_
#include "Forward.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Builder.h"
#include "backend/RefCounted.h"
#include "common/Constants.h"
#include "nxt/nxtcpp.h"
@ -72,4 +73,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_BINDGROUPLAYOUT_H_
#endif // BACKEND_BINDGROUPLAYOUT_H_

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "Buffer.h"
#include "backend/Buffer.h"
#include "Device.h"
#include "backend/Device.h"
#include <utility>
#include <cstdio>

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_BUFFER_H_
#define BACKEND_COMMON_BUFFER_H_
#ifndef BACKEND_BUFFER_H_
#define BACKEND_BUFFER_H_
#include "Forward.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Builder.h"
#include "backend/RefCounted.h"
#include "nxt/nxtcpp.h"
@ -123,4 +123,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_BUFFER_H_
#endif // BACKEND_BUFFER_H_

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "Builder.h"
#include "backend/Builder.h"
#include "Device.h"
#include "backend/Device.h"
namespace backend {

View File

@ -12,11 +12,11 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_BUILDER_H_
#define BACKEND_COMMON_BUILDER_H_
#ifndef BACKEND_BUILDER_H_
#define BACKEND_BUILDER_H_
#include "Forward.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/RefCounted.h"
#include "nxt/nxtcpp.h"
@ -107,4 +107,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_BUILDER_H_
#endif // BACKEND_BUILDER_H_

View File

@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
set(COMMON_DIR ${CMAKE_CURRENT_SOURCE_DIR}/common)
set(BACKEND_DIR ${CMAKE_CURRENT_SOURCE_DIR})
set(METAL_DIR ${CMAKE_CURRENT_SOURCE_DIR}/metal)
set(NULL_DIR ${CMAKE_CURRENT_SOURCE_DIR}/null)
set(OPENGL_DIR ${CMAKE_CURRENT_SOURCE_DIR}/opengl)
@ -20,52 +20,48 @@ set(D3D12_DIR ${CMAKE_CURRENT_SOURCE_DIR}/d3d12)
set(TESTS_DIR ${CMAKE_CURRENT_SOURCE_DIR}/tests)
list(APPEND BACKEND_SOURCES
${COMMON_DIR}/BindGroup.cpp
${COMMON_DIR}/BindGroup.h
${COMMON_DIR}/BindGroupLayout.cpp
${COMMON_DIR}/BindGroupLayout.h
${COMMON_DIR}/BitSetIterator.h
${COMMON_DIR}/Builder.cpp
${COMMON_DIR}/Builder.h
${COMMON_DIR}/Buffer.cpp
${COMMON_DIR}/Buffer.h
${COMMON_DIR}/CommandAllocator.cpp
${COMMON_DIR}/CommandAllocator.h
${COMMON_DIR}/CommandBuffer.cpp
${COMMON_DIR}/CommandBuffer.h
${COMMON_DIR}/DepthStencilState.cpp
${COMMON_DIR}/DepthStencilState.h
${COMMON_DIR}/CommandBufferStateTracker.cpp
${COMMON_DIR}/CommandBufferStateTracker.h
${COMMON_DIR}/Device.cpp
${COMMON_DIR}/Device.h
${COMMON_DIR}/Forward.h
${COMMON_DIR}/Framebuffer.cpp
${COMMON_DIR}/Framebuffer.h
${COMMON_DIR}/InputState.cpp
${COMMON_DIR}/InputState.h
${COMMON_DIR}/Math.cpp
${COMMON_DIR}/Math.h
${COMMON_DIR}/PerStage.cpp
${COMMON_DIR}/PerStage.h
${COMMON_DIR}/Pipeline.cpp
${COMMON_DIR}/Pipeline.h
${COMMON_DIR}/PipelineLayout.cpp
${COMMON_DIR}/PipelineLayout.h
${COMMON_DIR}/Queue.cpp
${COMMON_DIR}/Queue.h
${COMMON_DIR}/RenderPass.cpp
${COMMON_DIR}/RenderPass.h
${COMMON_DIR}/RefCounted.cpp
${COMMON_DIR}/RefCounted.h
${COMMON_DIR}/Sampler.cpp
${COMMON_DIR}/Sampler.h
${COMMON_DIR}/SerialQueue.h
${COMMON_DIR}/ShaderModule.cpp
${COMMON_DIR}/ShaderModule.h
${COMMON_DIR}/Texture.cpp
${COMMON_DIR}/Texture.h
${COMMON_DIR}/ToBackend.h
${BACKEND_DIR}/BindGroup.cpp
${BACKEND_DIR}/BindGroup.h
${BACKEND_DIR}/BindGroupLayout.cpp
${BACKEND_DIR}/BindGroupLayout.h
${BACKEND_DIR}/Builder.cpp
${BACKEND_DIR}/Builder.h
${BACKEND_DIR}/Buffer.cpp
${BACKEND_DIR}/Buffer.h
${BACKEND_DIR}/CommandAllocator.cpp
${BACKEND_DIR}/CommandAllocator.h
${BACKEND_DIR}/CommandBuffer.cpp
${BACKEND_DIR}/CommandBuffer.h
${BACKEND_DIR}/DepthStencilState.cpp
${BACKEND_DIR}/DepthStencilState.h
${BACKEND_DIR}/CommandBufferStateTracker.cpp
${BACKEND_DIR}/CommandBufferStateTracker.h
${BACKEND_DIR}/Device.cpp
${BACKEND_DIR}/Device.h
${BACKEND_DIR}/Forward.h
${BACKEND_DIR}/Framebuffer.cpp
${BACKEND_DIR}/Framebuffer.h
${BACKEND_DIR}/InputState.cpp
${BACKEND_DIR}/InputState.h
${BACKEND_DIR}/PerStage.cpp
${BACKEND_DIR}/PerStage.h
${BACKEND_DIR}/Pipeline.cpp
${BACKEND_DIR}/Pipeline.h
${BACKEND_DIR}/PipelineLayout.cpp
${BACKEND_DIR}/PipelineLayout.h
${BACKEND_DIR}/Queue.cpp
${BACKEND_DIR}/Queue.h
${BACKEND_DIR}/RenderPass.cpp
${BACKEND_DIR}/RenderPass.h
${BACKEND_DIR}/RefCounted.cpp
${BACKEND_DIR}/RefCounted.h
${BACKEND_DIR}/Sampler.cpp
${BACKEND_DIR}/Sampler.h
${BACKEND_DIR}/ShaderModule.cpp
${BACKEND_DIR}/ShaderModule.h
${BACKEND_DIR}/Texture.cpp
${BACKEND_DIR}/Texture.h
${BACKEND_DIR}/ToBackend.h
)
# OpenGL Backend
@ -79,7 +75,7 @@ Generate(
-T opengl
)
target_link_libraries(opengl_autogen glfw glad nxtcpp)
target_include_directories(opengl_autogen PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
target_include_directories(opengl_autogen PRIVATE ${SRC_DIR})
target_include_directories(opengl_autogen PUBLIC ${GENERATED_DIR})
SetCXX14(opengl_autogen)
SetPIC(opengl_autogen)
@ -116,7 +112,7 @@ Generate(
)
target_link_libraries(null_autogen nxtcpp)
target_include_directories(null_autogen PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
target_include_directories(null_autogen PUBLIC ${GENERATED_DIR})
target_include_directories(null_autogen PUBLIC ${SRC_DIR})
SetCXX14(null_autogen)
SetPIC(null_autogen)
@ -137,7 +133,7 @@ if (APPLE)
-T metal
)
target_link_libraries(metal_autogen glfw glad nxtcpp "-framework QuartzCore" "-framework Metal")
target_include_directories(metal_autogen PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
target_include_directories(metal_autogen PRIVATE ${SRC_DIR})
target_include_directories(metal_autogen PUBLIC ${GENERATED_DIR})
SetCXX14(metal_autogen)
SetPIC(metal_autogen)
@ -231,7 +227,7 @@ if (WIN32)
target_link_libraries(d3d12_autogen glfw nxtcpp ${D3D12_LIBRARIES})
target_include_directories(d3d12_autogen SYSTEM PRIVATE ${D3D12_INCLUDE_DIR} ${DXGI_INCLUDE_DIR})
target_include_directories(d3d12_autogen PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
target_include_directories(d3d12_autogen PRIVATE ${SRC_DIR})
target_include_directories(d3d12_autogen PUBLIC ${GENERATED_DIR})
SetCXX14(d3d12_autogen)
SetPIC(d3d12_autogen)
@ -274,12 +270,11 @@ endif()
add_library(nxt_backend STATIC ${BACKEND_SOURCES})
target_link_libraries(nxt_backend opengl_autogen null_autogen glfw glad spirv-cross)
target_link_libraries(nxt_backend nxt_common opengl_autogen null_autogen glfw glad spirv-cross)
if (APPLE)
target_link_libraries(nxt_backend metal_autogen)
endif()
if (WIN32)
target_link_libraries(nxt_backend d3d12_autogen)
endif()
target_include_directories(nxt_backend PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
SetCXX14(nxt_backend)

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "CommandAllocator.h"
#include "backend/CommandAllocator.h"
#include "Math.h"
#include "common/Math.h"
#include <algorithm>
#include <cassert>

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_COMMAND_ALLOCATOR_H_
#define BACKEND_COMMON_COMMAND_ALLOCATOR_H_
#ifndef BACKEND_COMMAND_ALLOCATOR_H_
#define BACKEND_COMMAND_ALLOCATOR_H_
#include <cstdint>
#include <cstddef>
@ -147,4 +147,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_COMMAND_ALLOCATOR_H_
#endif // BACKEND_COMMAND_ALLOCATOR_H_

View File

@ -12,17 +12,17 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "CommandBuffer.h"
#include "backend/CommandBuffer.h"
#include "BindGroup.h"
#include "Buffer.h"
#include "Commands.h"
#include "CommandBufferStateTracker.h"
#include "Device.h"
#include "InputState.h"
#include "Pipeline.h"
#include "PipelineLayout.h"
#include "Texture.h"
#include "backend/BindGroup.h"
#include "backend/Buffer.h"
#include "backend/Commands.h"
#include "backend/CommandBufferStateTracker.h"
#include "backend/Device.h"
#include "backend/InputState.h"
#include "backend/Pipeline.h"
#include "backend/PipelineLayout.h"
#include "backend/Texture.h"
#include <cstring>
#include <map>

View File

@ -12,14 +12,14 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_COMMANDBUFFER_H_
#define BACKEND_COMMON_COMMANDBUFFER_H_
#ifndef BACKEND_COMMANDBUFFER_H_
#define BACKEND_COMMANDBUFFER_H_
#include "nxt/nxtcpp.h"
#include "CommandAllocator.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/CommandAllocator.h"
#include "backend/Builder.h"
#include "backend/RefCounted.h"
#include <memory>
#include <set>
@ -103,4 +103,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_COMMANDBUFFER_H_
#endif // BACKEND_COMMANDBUFFER_H_

View File

@ -12,19 +12,19 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "CommandBufferStateTracker.h"
#include "backend/CommandBufferStateTracker.h"
#include "Forward.h"
#include "BindGroup.h"
#include "BindGroupLayout.h"
#include "BitSetIterator.h"
#include "Buffer.h"
#include "Framebuffer.h"
#include "InputState.h"
#include "Pipeline.h"
#include "PipelineLayout.h"
#include "RenderPass.h"
#include "Texture.h"
#include "backend/Forward.h"
#include "backend/BindGroup.h"
#include "backend/BindGroupLayout.h"
#include "backend/Buffer.h"
#include "backend/Framebuffer.h"
#include "backend/InputState.h"
#include "backend/Pipeline.h"
#include "backend/PipelineLayout.h"
#include "backend/RenderPass.h"
#include "backend/Texture.h"
#include "common/BitSetIterator.h"
namespace backend {
CommandBufferStateTracker::CommandBufferStateTracker(CommandBufferBuilder* builder)

View File

@ -12,10 +12,11 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_COMMANDBUFFERSTATETRACKER_H
#define BACKEND_COMMON_COMMANDBUFFERSTATETRACKER_H
#ifndef BACKEND_COMMANDBUFFERSTATETRACKER_H
#define BACKEND_COMMANDBUFFERSTATETRACKER_H
#include "CommandBuffer.h"
#include "backend/CommandBuffer.h"
#include "common/Constants.h"
#include <bitset>
#include <map>
@ -100,4 +101,4 @@ namespace backend {
};
}
#endif // BACKEND_COMMON_COMMANDBUFFERSTATETRACKER_H
#endif // BACKEND_COMMANDBUFFERSTATETRACKER_H

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_COMMANDS_H_
#define BACKEND_COMMON_COMMANDS_H_
#ifndef BACKEND_COMMANDS_H_
#define BACKEND_COMMANDS_H_
#include "Framebuffer.h"
#include "RenderPass.h"
#include "Texture.h"
#include "backend/Framebuffer.h"
#include "backend/RenderPass.h"
#include "backend/Texture.h"
#include "nxt/nxtcpp.h"
@ -155,4 +155,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_COMMANDS_H_
#endif // BACKEND_COMMANDS_H_

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "DepthStencilState.h"
#include "backend/DepthStencilState.h"
#include "Device.h"
#include "backend/Device.h"
namespace backend {

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_DEPTHSTENCILSTATE_H_
#define BACKEND_COMMON_DEPTHSTENCILSTATE_H_
#ifndef BACKEND_DEPTHSTENCILSTATE_H_
#define BACKEND_DEPTHSTENCILSTATE_H_
#include "Forward.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Builder.h"
#include "backend/RefCounted.h"
#include "nxt/nxtcpp.h"
@ -81,4 +81,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_DEPTHSTENCILSTATE_H_
#endif // BACKEND_DEPTHSTENCILSTATE_H_

View File

@ -12,22 +12,22 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "Device.h"
#include "backend/Device.h"
#include "BindGroup.h"
#include "BindGroupLayout.h"
#include "Buffer.h"
#include "CommandBuffer.h"
#include "DepthStencilState.h"
#include "Framebuffer.h"
#include "InputState.h"
#include "Pipeline.h"
#include "PipelineLayout.h"
#include "Queue.h"
#include "RenderPass.h"
#include "Sampler.h"
#include "ShaderModule.h"
#include "Texture.h"
#include "backend/BindGroup.h"
#include "backend/BindGroupLayout.h"
#include "backend/Buffer.h"
#include "backend/CommandBuffer.h"
#include "backend/DepthStencilState.h"
#include "backend/Framebuffer.h"
#include "backend/InputState.h"
#include "backend/Pipeline.h"
#include "backend/PipelineLayout.h"
#include "backend/Queue.h"
#include "backend/RenderPass.h"
#include "backend/Sampler.h"
#include "backend/ShaderModule.h"
#include "backend/Texture.h"
#include <unordered_set>

View File

@ -12,11 +12,11 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_DEVICEBASE_H_
#define BACKEND_COMMON_DEVICEBASE_H_
#ifndef BACKEND_DEVICEBASE_H_
#define BACKEND_DEVICEBASE_H_
#include "common/Forward.h"
#include "common/RefCounted.h"
#include "backend/Forward.h"
#include "backend/RefCounted.h"
#include "nxt/nxtcpp.h"
@ -103,4 +103,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_DEVICEBASE_H_
#endif // BACKEND_DEVICEBASE_H_

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_FORWARD_H_
#define BACKEND_COMMON_FORWARD_H_
#ifndef BACKEND_FORWARD_H_
#define BACKEND_FORWARD_H_
#include <cassert>
#include <cstdint>
@ -63,18 +63,7 @@ namespace backend {
template<typename T>
class PerStage;
using Serial = uint64_t;
// TODO(cwallez@chromium.org): where should constants live?
static constexpr uint32_t kMaxPushConstants = 32u;
static constexpr uint32_t kMaxBindGroups = 4u;
static constexpr uint32_t kMaxBindingsPerGroup = 16u; // TODO(cwallez@chromium.org): investigate bindgroup limits
static constexpr uint32_t kMaxVertexAttributes = 16u;
static constexpr uint32_t kMaxVertexInputs = 16u;
static constexpr uint32_t kNumStages = 3;
static constexpr uint32_t kMaxColorAttachments = 4u;
enum PushConstantType : uint8_t;
}
#endif // BACKEND_COMMON_FORWARD_H_
#endif // BACKEND_FORWARD_H_

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "Framebuffer.h"
#include "backend/Framebuffer.h"
#include "Buffer.h"
#include "Device.h"
#include "RenderPass.h"
#include "Texture.h"
#include "backend/Buffer.h"
#include "backend/Device.h"
#include "backend/RenderPass.h"
#include "backend/Texture.h"
namespace backend {

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_FRAMEBUFFER_H_
#define BACKEND_COMMON_FRAMEBUFFER_H_
#ifndef BACKEND_FRAMEBUFFER_H_
#define BACKEND_FRAMEBUFFER_H_
#include "Builder.h"
#include "Forward.h"
#include "RefCounted.h"
#include "backend/Builder.h"
#include "backend/Forward.h"
#include "backend/RefCounted.h"
#include "nxt/nxtcpp.h"
@ -66,4 +66,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_FRAMEBUFFER_H_
#endif // BACKEND_FRAMEBUFFER_H_

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "InputState.h"
#include "backend/InputState.h"
#include "Device.h"
#include "backend/Device.h"
namespace backend {

View File

@ -12,12 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_INPUTSTATE_H_
#define BACKEND_COMMON_INPUTSTATE_H_
#ifndef BACKEND_INPUTSTATE_H_
#define BACKEND_INPUTSTATE_H_
#include "Forward.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Builder.h"
#include "backend/RefCounted.h"
#include "common/Constants.h"
#include "nxt/nxtcpp.h"
@ -80,4 +81,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_INPUTSTATE_H_
#endif // BACKEND_INPUTSTATE_H_

View File

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "PerStage.h"
#include "backend/PerStage.h"
namespace backend {

View File

@ -12,14 +12,17 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_PERSTAGE_H_
#define BACKEND_COMMON_PERSTAGE_H_
#ifndef BACKEND_PERSTAGE_H_
#define BACKEND_PERSTAGE_H_
#include "BitSetIterator.h"
#include "common/BitSetIterator.h"
#include "common/Constants.h"
#include "nxt/nxtcpp.h"
#include <array>
#include <cassert>
#define ASSERT assert
namespace backend {
@ -65,4 +68,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_PERSTAGE_H_
#endif // BACKEND_PERSTAGE_H_

View File

@ -12,14 +12,14 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "Pipeline.h"
#include "backend/Pipeline.h"
#include "Device.h"
#include "DepthStencilState.h"
#include "InputState.h"
#include "PipelineLayout.h"
#include "RenderPass.h"
#include "ShaderModule.h"
#include "backend/Device.h"
#include "backend/DepthStencilState.h"
#include "backend/InputState.h"
#include "backend/PipelineLayout.h"
#include "backend/RenderPass.h"
#include "backend/ShaderModule.h"
namespace backend {

View File

@ -12,13 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_PIPELINE_H_
#define BACKEND_COMMON_PIPELINE_H_
#ifndef BACKEND_PIPELINE_H_
#define BACKEND_PIPELINE_H_
#include "Forward.h"
#include "Builder.h"
#include "PerStage.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Builder.h"
#include "backend/PerStage.h"
#include "backend/RefCounted.h"
#include "nxt/nxtcpp.h"
@ -97,4 +97,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_PIPELINE_H_
#endif // BACKEND_PIPELINE_H_

View File

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "PipelineLayout.h"
#include "backend/PipelineLayout.h"
#include "BindGroupLayout.h"
#include "Device.h"
#include "backend/BindGroupLayout.h"
#include "backend/Device.h"
namespace backend {

View File

@ -12,12 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_PIPELINELAYOUT_H_
#define BACKEND_COMMON_PIPELINELAYOUT_H_
#ifndef BACKEND_PIPELINELAYOUT_H_
#define BACKEND_PIPELINELAYOUT_H_
#include "Forward.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Builder.h"
#include "backend/RefCounted.h"
#include "common/Constants.h"
#include "nxt/nxtcpp.h"
@ -58,4 +59,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_PIPELINELAYOUT_H_
#endif // BACKEND_PIPELINELAYOUT_H_

View File

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "Queue.h"
#include "backend/Queue.h"
#include "Device.h"
#include "CommandBuffer.h"
#include "backend/Device.h"
#include "backend/CommandBuffer.h"
namespace backend {

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_QUEUE_H_
#define BACKEND_COMMON_QUEUE_H_
#ifndef BACKEND_QUEUE_H_
#define BACKEND_QUEUE_H_
#include "Forward.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Builder.h"
#include "backend/RefCounted.h"
#include "nxt/nxtcpp.h"
@ -58,4 +58,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_QUEUE_H_
#endif // BACKEND_QUEUE_H_

View File

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "RefCounted.h"
#include "backend/RefCounted.h"
#include <cassert>
#define ASSERT assert

View File

@ -12,8 +12,8 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_REFCOUNTED_H_
#define BACKEND_COMMON_REFCOUNTED_H_
#ifndef BACKEND_REFCOUNTED_H_
#define BACKEND_REFCOUNTED_H_
#include <cstdint>
@ -123,4 +123,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_REFCOUNTED_H_
#endif // BACKEND_REFCOUNTED_H_

View File

@ -12,11 +12,11 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "RenderPass.h"
#include "backend/RenderPass.h"
#include "Buffer.h"
#include "Device.h"
#include "Texture.h"
#include "backend/Buffer.h"
#include "backend/Device.h"
#include "backend/Texture.h"
namespace backend {

View File

@ -12,12 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_RENDERPASS_H_
#define BACKEND_COMMON_RENDERPASS_H_
#ifndef BACKEND_RENDERPASS_H_
#define BACKEND_RENDERPASS_H_
#include "Builder.h"
#include "Forward.h"
#include "RefCounted.h"
#include "backend/Builder.h"
#include "backend/Forward.h"
#include "backend/RefCounted.h"
#include "common/Constants.h"
#include "nxt/nxtcpp.h"
@ -80,4 +81,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_RENDERPASS_H_
#endif // BACKEND_RENDERPASS_H_

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "Sampler.h"
#include "backend/Sampler.h"
#include "Device.h"
#include "backend/Device.h"
namespace backend {

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_SAMPLER_H_
#define BACKEND_COMMON_SAMPLER_H_
#ifndef BACKEND_SAMPLER_H_
#define BACKEND_SAMPLER_H_
#include "Forward.h"
#include "Buffer.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Buffer.h"
#include "backend/RefCounted.h"
#include "nxt/nxtcpp.h"
@ -53,4 +53,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_SAMPLER_H_
#endif // BACKEND_SAMPLER_H_

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "ShaderModule.h"
#include "backend/ShaderModule.h"
#include "BindGroupLayout.h"
#include "Device.h"
#include "Pipeline.h"
#include "PipelineLayout.h"
#include "backend/BindGroupLayout.h"
#include "backend/Device.h"
#include "backend/Pipeline.h"
#include "backend/PipelineLayout.h"
#include <spirv-cross/spirv_cross.hpp>

View File

@ -12,12 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_SHADERMODULE_H_
#define BACKEND_COMMON_SHADERMODULE_H_
#ifndef BACKEND_SHADERMODULE_H_
#define BACKEND_SHADERMODULE_H_
#include "Forward.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Builder.h"
#include "backend/RefCounted.h"
#include "common/Constants.h"
#include "nxt/nxtcpp.h"
@ -90,4 +91,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_SHADERMODULE_H_
#endif // BACKEND_SHADERMODULE_H_

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "Texture.h"
#include "backend/Texture.h"
#include "Device.h"
#include "backend/Device.h"
namespace backend {

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_TEXTURE_H_
#define BACKEND_COMMON_TEXTURE_H_
#ifndef BACKEND_TEXTURE_H_
#define BACKEND_TEXTURE_H_
#include "Forward.h"
#include "Builder.h"
#include "RefCounted.h"
#include "backend/Forward.h"
#include "backend/Builder.h"
#include "backend/RefCounted.h"
#include "nxt/nxtcpp.h"
@ -115,4 +115,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_TEXTURE_H_
#endif // BACKEND_TEXTURE_H_

View File

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef BACKEND_COMMON_TOBACKEND_H_
#define BACKEND_COMMON_TOBACKEND_H_
#ifndef BACKEND_TOBACKEND_H_
#define BACKEND_TOBACKEND_H_
#include "Forward.h"
#include "backend/Forward.h"
namespace backend {
@ -137,4 +137,4 @@ namespace backend {
}
#endif // BACKEND_COMMON_TOBACKEND_H_
#endif // BACKEND_TOBACKEND_H_

View File

@ -13,13 +13,13 @@
// limitations under the License.
#include "common/BitSetIterator.h"
#include "BindGroupD3D12.h"
#include "BindGroupLayoutD3D12.h"
#include "BufferD3D12.h"
#include "SamplerD3D12.h"
#include "TextureD3D12.h"
#include "backend/d3d12/BindGroupD3D12.h"
#include "backend/d3d12/BindGroupLayoutD3D12.h"
#include "backend/d3d12/BufferD3D12.h"
#include "backend/d3d12/SamplerD3D12.h"
#include "backend/d3d12/TextureD3D12.h"
#include "D3D12Backend.h"
#include "backend/d3d12/D3D12Backend.h"
namespace backend {
namespace d3d12 {

View File

@ -15,11 +15,11 @@
#ifndef BACKEND_D3D12_BINDGROUPD3D12_H_
#define BACKEND_D3D12_BINDGROUPD3D12_H_
#include "common/BindGroup.h"
#include "backend/BindGroup.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
#include "DescriptorHeapAllocator.h"
#include "backend/d3d12/DescriptorHeapAllocator.h"
namespace backend {
namespace d3d12 {

View File

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "BindGroupLayoutD3D12.h"
#include "backend/d3d12/BindGroupLayoutD3D12.h"
#include "common/BitSetIterator.h"
#include "D3D12Backend.h"
#include "backend/d3d12/D3D12Backend.h"
namespace backend {
namespace d3d12 {

View File

@ -15,9 +15,9 @@
#ifndef BACKEND_D3D12_BINDGROUPLAYOUTD3D12_H_
#define BACKEND_D3D12_BINDGROUPLAYOUTD3D12_H_
#include "common/BindGroupLayout.h"
#include "backend/BindGroupLayout.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -12,11 +12,11 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "BufferD3D12.h"
#include "backend/d3d12/BufferD3D12.h"
#include "D3D12Backend.h"
#include "ResourceAllocator.h"
#include "ResourceUploader.h"
#include "backend/d3d12/D3D12Backend.h"
#include "backend/d3d12/ResourceAllocator.h"
#include "backend/d3d12/ResourceUploader.h"
namespace backend {
namespace d3d12 {

View File

@ -15,10 +15,10 @@
#ifndef BACKEND_D3D12_BUFFERD3D12_H_
#define BACKEND_D3D12_BUFFERD3D12_H_
#include "common/Buffer.h"
#include "backend/Buffer.h"
#include "common/SerialQueue.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "CommandAllocatorManager.h"
#include "backend/d3d12/CommandAllocatorManager.h"
#include "D3D12Backend.h"
#include "backend/d3d12/D3D12Backend.h"
#include "common/BitSetIterator.h"

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_D3D12_COMMANDALLOCATORMANAGER_H_
#define BACKEND_D3D12_COMMANDALLOCATORMANAGER_H_
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
#include "common/SerialQueue.h"

View File

@ -12,19 +12,19 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "CommandBufferD3D12.h"
#include "backend/d3d12/CommandBufferD3D12.h"
#include "common/Commands.h"
#include "D3D12Backend.h"
#include "BindGroupD3D12.h"
#include "BindGroupLayoutD3D12.h"
#include "BufferD3D12.h"
#include "DescriptorHeapAllocator.h"
#include "InputStateD3D12.h"
#include "PipelineD3D12.h"
#include "PipelineLayoutD3D12.h"
#include "SamplerD3D12.h"
#include "TextureD3D12.h"
#include "backend/Commands.h"
#include "backend/d3d12/D3D12Backend.h"
#include "backend/d3d12/BindGroupD3D12.h"
#include "backend/d3d12/BindGroupLayoutD3D12.h"
#include "backend/d3d12/BufferD3D12.h"
#include "backend/d3d12/DescriptorHeapAllocator.h"
#include "backend/d3d12/InputStateD3D12.h"
#include "backend/d3d12/PipelineD3D12.h"
#include "backend/d3d12/PipelineLayoutD3D12.h"
#include "backend/d3d12/SamplerD3D12.h"
#include "backend/d3d12/TextureD3D12.h"
#include "ResourceAllocator.h"

View File

@ -15,10 +15,10 @@
#ifndef BACKEND_D3D12_COMMANDBUFFERD3D12_H_
#define BACKEND_D3D12_COMMANDBUFFERD3D12_H_
#include "common/CommandAllocator.h"
#include "common/CommandBuffer.h"
#include "backend/CommandAllocator.h"
#include "backend/CommandBuffer.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -12,24 +12,24 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "D3D12Backend.h"
#include "backend/d3d12/D3D12Backend.h"
#include "BindGroupD3D12.h"
#include "BindGroupLayoutD3D12.h"
#include "BufferD3D12.h"
#include "CommandBufferD3D12.h"
#include "InputStateD3D12.h"
#include "PipelineD3D12.h"
#include "PipelineLayoutD3D12.h"
#include "QueueD3D12.h"
#include "SamplerD3D12.h"
#include "ShaderModuleD3D12.h"
#include "TextureD3D12.h"
#include "backend/d3d12/BindGroupD3D12.h"
#include "backend/d3d12/BindGroupLayoutD3D12.h"
#include "backend/d3d12/BufferD3D12.h"
#include "backend/d3d12/CommandBufferD3D12.h"
#include "backend/d3d12/InputStateD3D12.h"
#include "backend/d3d12/PipelineD3D12.h"
#include "backend/d3d12/PipelineLayoutD3D12.h"
#include "backend/d3d12/QueueD3D12.h"
#include "backend/d3d12/SamplerD3D12.h"
#include "backend/d3d12/ShaderModuleD3D12.h"
#include "backend/d3d12/TextureD3D12.h"
#include "CommandAllocatorManager.h"
#include "DescriptorHeapAllocator.h"
#include "ResourceAllocator.h"
#include "ResourceUploader.h"
#include "backend/d3d12/CommandAllocatorManager.h"
#include "backend/d3d12/DescriptorHeapAllocator.h"
#include "backend/d3d12/ResourceAllocator.h"
#include "backend/d3d12/ResourceUploader.h"
namespace backend {
namespace d3d12 {

View File

@ -17,21 +17,21 @@
#include "nxt/nxtcpp.h"
#include "common/Buffer.h"
#include "common/BindGroup.h"
#include "common/BindGroupLayout.h"
#include "common/Device.h"
#include "common/Framebuffer.h"
#include "common/DepthStencilState.h"
#include "common/InputState.h"
#include "common/PipelineLayout.h"
#include "common/Queue.h"
#include "common/RenderPass.h"
#include "common/Sampler.h"
#include "common/Texture.h"
#include "common/ToBackend.h"
#include "backend/Buffer.h"
#include "backend/BindGroup.h"
#include "backend/BindGroupLayout.h"
#include "backend/Device.h"
#include "backend/Framebuffer.h"
#include "backend/DepthStencilState.h"
#include "backend/InputState.h"
#include "backend/PipelineLayout.h"
#include "backend/Queue.h"
#include "backend/RenderPass.h"
#include "backend/Sampler.h"
#include "backend/Texture.h"
#include "backend/ToBackend.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "DescriptorHeapAllocator.h"
#include "backend/d3d12/DescriptorHeapAllocator.h"
#include "D3D12Backend.h"
#include "backend/d3d12/D3D12Backend.h"
namespace backend {
namespace d3d12 {

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_D3D12_DESCRIPTORHEAPALLOCATOR_H_
#define BACKEND_D3D12_DESCRIPTORHEAPALLOCATOR_H_
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
#include "common/SerialQueue.h"
#include <array>

View File

@ -12,15 +12,15 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "D3D12Backend.h"
#include "BindGroupD3D12.h"
#include "BindGroupLayoutD3D12.h"
#include "BufferD3D12.h"
#include "CommandBufferD3D12.h"
#include "InputStateD3D12.h"
#include "PipelineD3D12.h"
#include "PipelineLayoutD3D12.h"
#include "QueueD3D12.h"
#include "SamplerD3D12.h"
#include "ShaderModuleD3D12.h"
#include "TextureD3D12.h"
#include "backend/d3d12/D3D12Backend.h"
#include "backend/d3d12/BindGroupD3D12.h"
#include "backend/d3d12/BindGroupLayoutD3D12.h"
#include "backend/d3d12/BufferD3D12.h"
#include "backend/d3d12/CommandBufferD3D12.h"
#include "backend/d3d12/InputStateD3D12.h"
#include "backend/d3d12/PipelineD3D12.h"
#include "backend/d3d12/PipelineLayoutD3D12.h"
#include "backend/d3d12/QueueD3D12.h"
#include "backend/d3d12/SamplerD3D12.h"
#include "backend/d3d12/ShaderModuleD3D12.h"
#include "backend/d3d12/TextureD3D12.h"

View File

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "InputStateD3D12.h"
#include "backend/d3d12/InputStateD3D12.h"
namespace backend {
namespace d3d12 {

View File

@ -15,9 +15,9 @@
#ifndef BACKEND_D3D12_INPUTSTATED3D12_H_
#define BACKEND_D3D12_INPUTSTATED3D12_H_
#include "common/InputState.h"
#include "backend/InputState.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -12,12 +12,12 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "PipelineD3D12.h"
#include "backend/d3d12/PipelineD3D12.h"
#include "D3D12Backend.h"
#include "InputStateD3D12.h"
#include "ShaderModuleD3D12.h"
#include "PipelineLayoutD3D12.h"
#include "backend/d3d12/D3D12Backend.h"
#include "backend/d3d12/InputStateD3D12.h"
#include "backend/d3d12/ShaderModuleD3D12.h"
#include "backend/d3d12/PipelineLayoutD3D12.h"
#include <d3dcompiler.h>

View File

@ -15,9 +15,9 @@
#ifndef BACKEND_D3D12_PIPELINED3D12_H_
#define BACKEND_D3D12_PIPELINED3D12_H_
#include "common/Pipeline.h"
#include "backend/Pipeline.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "PipelineLayoutD3D12.h"
#include "backend/d3d12/PipelineLayoutD3D12.h"
#include "D3D12Backend.h"
#include "BindGroupLayoutD3D12.h"
#include "backend/d3d12/D3D12Backend.h"
#include "backend/d3d12/BindGroupLayoutD3D12.h"
using Microsoft::WRL::ComPtr;

View File

@ -15,9 +15,9 @@
#ifndef BACKEND_D3D12_PIPELINELAYOUTD3D12_H_
#define BACKEND_D3D12_PIPELINELAYOUTD3D12_H_
#include "common/PipelineLayout.h"
#include "backend/PipelineLayout.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "QueueD3D12.h"
#include "backend/d3d12/QueueD3D12.h"
#include "D3D12Backend.h"
#include "CommandBufferD3D12.h"
#include "backend/d3d12/D3D12Backend.h"
#include "backend/d3d12/CommandBufferD3D12.h"
namespace backend {
namespace d3d12 {

View File

@ -15,9 +15,9 @@
#ifndef BACKEND_D3D12_QUEUED3D12_H_
#define BACKEND_D3D12_QUEUED3D12_H_
#include "common/Queue.h"
#include "backend/Queue.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "ResourceAllocator.h"
#include "backend/d3d12/ResourceAllocator.h"
#include "D3D12Backend.h"
#include "backend/d3d12/D3D12Backend.h"
namespace backend {
namespace d3d12 {

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_D3D12_RESOURCEALLOCATIONMANAGER_H_
#define BACKEND_D3D12_RESOURCEALLOCATIONMANAGER_H_
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
#include "common/SerialQueue.h"

View File

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "ResourceUploader.h"
#include "backend/d3d12/ResourceUploader.h"
#include "D3D12Backend.h"
#include "ResourceAllocator.h"
#include "backend/d3d12/D3D12Backend.h"
#include "backend/d3d12/ResourceAllocator.h"
namespace backend {
namespace d3d12 {

View File

@ -15,9 +15,9 @@
#ifndef BACKEND_D3D12_RESOURCEUPLOADER_H_
#define BACKEND_D3D12_RESOURCEUPLOADER_H_
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
#include "common/Forward.h"
#include "backend/Forward.h"
namespace backend {
namespace d3d12 {

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "SamplerD3D12.h"
#include "backend/d3d12/SamplerD3D12.h"
#include "D3D12Backend.h"
#include "backend/d3d12/D3D12Backend.h"
namespace backend {
namespace d3d12 {

View File

@ -15,9 +15,9 @@
#ifndef BACKEND_D3D12_SAMPLERD3D12_H_
#define BACKEND_D3D12_SAMPLERD3D12_H_
#include "common/Sampler.h"
#include "backend/Sampler.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "ShaderModuleD3D12.h"
#include "backend/d3d12/ShaderModuleD3D12.h"
#include <spirv-cross/spirv_hlsl.hpp>

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_D3D12_SHADERMODULED3D12_H_
#define BACKEND_D3D12_SHADERMODULED3D12_H_
#include "common/ShaderModule.h"
#include "backend/ShaderModule.h"
namespace backend {
namespace d3d12 {

View File

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "TextureD3D12.h"
#include "backend/d3d12/TextureD3D12.h"
#include "D3D12Backend.h"
#include "ResourceAllocator.h"
#include "backend/d3d12/D3D12Backend.h"
#include "backend/d3d12/ResourceAllocator.h"
namespace backend {
namespace d3d12 {

View File

@ -15,9 +15,9 @@
#ifndef BACKEND_D3D12_TEXTURED3D12_H_
#define BACKEND_D3D12_TEXTURED3D12_H_
#include "common/Texture.h"
#include "backend/Texture.h"
#include "d3d12_platform.h"
#include "backend/d3d12/d3d12_platform.h"
namespace backend {
namespace d3d12 {

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_METAL_BUFFERMTL_H_
#define BACKEND_METAL_BUFFERMTL_H_
#include "common/Buffer.h"
#include "backend/Buffer.h"
#include "common/SerialQueue.h"
#import <Metal/Metal.h>

View File

@ -12,10 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "BufferMTL.h"
#include "backend/metal/BufferMTL.h"
#include "MetalBackend.h"
#include "ResourceUploader.h"
#include "backend/metal/MetalBackend.h"
#include "backend/metal/ResourceUploader.h"
namespace backend {
namespace metal {

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_METAL_COMMANDBUFFERMTL_H_
#define BACKEND_METAL_COMMANDBUFFERMTL_H_
#include "common/CommandBuffer.h"
#include "backend/CommandBuffer.h"
#import <Metal/Metal.h>

View File

@ -12,17 +12,17 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "CommandBufferMTL.h"
#include "backend/metal/CommandBufferMTL.h"
#include "common/Commands.h"
#include "BufferMTL.h"
#include "DepthStencilStateMTL.h"
#include "InputStateMTL.h"
#include "MetalBackend.h"
#include "PipelineMTL.h"
#include "PipelineLayoutMTL.h"
#include "SamplerMTL.h"
#include "TextureMTL.h"
#include "backend/Commands.h"
#include "backend/metal/BufferMTL.h"
#include "backend/metal/DepthStencilStateMTL.h"
#include "backend/metal/InputStateMTL.h"
#include "backend/metal/MetalBackend.h"
#include "backend/metal/PipelineMTL.h"
#include "backend/metal/PipelineLayoutMTL.h"
#include "backend/metal/SamplerMTL.h"
#include "backend/metal/TextureMTL.h"
namespace backend {
namespace metal {

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_METAL_DEPTHSTENCILSTATEMTL_H_
#define BACKEND_METAL_DEPTHSTENCILSTATEMTL_H_
#include "common/DepthStencilState.h"
#include "backend/DepthStencilState.h"
#import <Metal/Metal.h>

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "DepthStencilStateMTL.h"
#include "backend/metal/DepthStencilStateMTL.h"
#include "MetalBackend.h"
#include "backend/metal/MetalBackend.h"
namespace backend {
namespace metal {

View File

@ -12,13 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "MetalBackend.h"
#include "BufferMTL.h"
#include "CommandBufferMTL.h"
#include "DepthStencilStateMTL.h"
#include "InputStateMTL.h"
#include "PipelineMTL.h"
#include "PipelineLayoutMTL.h"
#include "SamplerMTL.h"
#include "ShaderModuleMTL.h"
#include "TextureMTL.h"
#include "backend/metal/MetalBackend.h"
#include "backend/metal/BufferMTL.h"
#include "backend/metal/CommandBufferMTL.h"
#include "backend/metal/DepthStencilStateMTL.h"
#include "backend/metal/InputStateMTL.h"
#include "backend/metal/PipelineMTL.h"
#include "backend/metal/PipelineLayoutMTL.h"
#include "backend/metal/SamplerMTL.h"
#include "backend/metal/ShaderModuleMTL.h"
#include "backend/metal/TextureMTL.h"

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_METAL_INPUTSTATEMTL_H_
#define BACKEND_METAL_INPUTSTATEMTL_H_
#include "common/InputState.h"
#include "backend/InputState.h"
#import <Metal/Metal.h>

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "InputStateMTL.h"
#include "backend/metal/InputStateMTL.h"
#include "MetalBackend.h"
#include "backend/metal/MetalBackend.h"
namespace backend {
namespace metal {

View File

@ -17,13 +17,14 @@
#include "nxt/nxtcpp.h"
#include "common/BindGroup.h"
#include "common/BindGroupLayout.h"
#include "common/Device.h"
#include "common/Framebuffer.h"
#include "common/Queue.h"
#include "common/RenderPass.h"
#include "common/ToBackend.h"
#include "backend/BindGroup.h"
#include "backend/BindGroupLayout.h"
#include "backend/Device.h"
#include "backend/Framebuffer.h"
#include "backend/Queue.h"
#include "backend/RenderPass.h"
#include "backend/ToBackend.h"
#include "common/Serial.h"
#include <type_traits>
#import <Metal/Metal.h>

View File

@ -12,20 +12,18 @@
// See the License for the specific language governing permissions and
// limitations under the License.
// TODO(kainino@chromium.org): split this backend into many files
#include "backend/metal/MetalBackend.h"
#include "MetalBackend.h"
#include "BufferMTL.h"
#include "CommandBufferMTL.h"
#include "DepthStencilStateMTL.h"
#include "InputStateMTL.h"
#include "PipelineMTL.h"
#include "PipelineLayoutMTL.h"
#include "ResourceUploader.h"
#include "SamplerMTL.h"
#include "ShaderModuleMTL.h"
#include "TextureMTL.h"
#include "backend/metal/BufferMTL.h"
#include "backend/metal/CommandBufferMTL.h"
#include "backend/metal/DepthStencilStateMTL.h"
#include "backend/metal/InputStateMTL.h"
#include "backend/metal/PipelineMTL.h"
#include "backend/metal/PipelineLayoutMTL.h"
#include "backend/metal/ResourceUploader.h"
#include "backend/metal/SamplerMTL.h"
#include "backend/metal/ShaderModuleMTL.h"
#include "backend/metal/TextureMTL.h"
namespace backend {
namespace metal {

View File

@ -15,9 +15,9 @@
#ifndef BACKEND_METAL_PIPELINELAYOUTMTL_H_
#define BACKEND_METAL_PIPELINELAYOUTMTL_H_
#include "common/PipelineLayout.h"
#include "backend/PipelineLayout.h"
#include "common/PerStage.h"
#include "backend/PerStage.h"
#import <Metal/Metal.h>

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "PipelineLayoutMTL.h"
#include "backend/metal/PipelineLayoutMTL.h"
#include "MetalBackend.h"
#include "backend/metal/MetalBackend.h"
namespace backend {
namespace metal {

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_METAL_PIPELINEMTL_H_
#define BACKEND_METAL_PIPELINEMTL_H_
#include "common/Pipeline.h"
#include "backend/Pipeline.h"
#import <Metal/Metal.h>

View File

@ -12,13 +12,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "PipelineMTL.h"
#include "backend/metal/PipelineMTL.h"
#include "DepthStencilStateMTL.h"
#include "InputStateMTL.h"
#include "MetalBackend.h"
#include "PipelineLayoutMTL.h"
#include "ShaderModuleMTL.h"
#include "backend/metal/DepthStencilStateMTL.h"
#include "backend/metal/InputStateMTL.h"
#include "backend/metal/MetalBackend.h"
#include "backend/metal/PipelineLayoutMTL.h"
#include "backend/metal/ShaderModuleMTL.h"
namespace backend {
namespace metal {

View File

@ -15,6 +15,7 @@
#ifndef BACKEND_METAL_RESOURCEUPLOADER_H_
#define BACKEND_METAL_RESOURCEUPLOADER_H_
#include "common/Serial.h"
#include "common/SerialQueue.h"
#import <Metal/Metal.h>

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "ResourceUploader.h"
#include "backend/metal/ResourceUploader.h"
#include "MetalBackend.h"
#include "backend/metal/MetalBackend.h"
namespace backend {
namespace metal {

View File

@ -15,7 +15,7 @@
#ifndef BACKEND_METAL_SAMPLERMTL_H_
#define BACKEND_METAL_SAMPLERMTL_H_
#include "common/Sampler.h"
#include "backend/Sampler.h"
#import <Metal/Metal.h>

View File

@ -12,9 +12,9 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#include "SamplerMTL.h"
#include "backend/metal/SamplerMTL.h"
#include "MetalBackend.h"
#include "backend/metal/MetalBackend.h"
namespace backend {
namespace metal {

Some files were not shown because too many files have changed in this diff Show More