Code Monkey home page Code Monkey logo

diligenttools's People

Contributors

alexandru-cazacu avatar andreymlashkin avatar azhirnov avatar dolphineye avatar hamyyy avatar luzpaz avatar mikhailgorobets avatar quantumfelidae avatar snaulx avatar thearperson avatar themostdiligent avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

diligenttools's Issues

RenderStateNotationParser: add defaults section

Add "Defaults" section to the json file where default values can be specified:

"Defaults": {
  "Shader" : {
      "SourceLanguage": "HLSL",
      "UseCombinedTextureSamplers": true
  }, 

  "Pipeline":{
  }
},

"Shaders": {

},

"Pipelines" : {
 "GraphicsPipeline": {
        "PrimitiveTopology": "TRIANGLE_LIST"
  }
}

This will be very helpful to avoid specifying the same states multiple times, e.g.

RenderStatePackager sysroot for metal tool not set properly when using --metal_ios from XCode -> Ninja environment

I'm seeing the following error when compiling --metal_ios I run the tool from XCode which runs Ninja as a subprocess:

metal:1:1: using sysroot for 'MacOSX' but targeting 'iPhone' [-Wincompatible-sysroot]

LLVM ERROR: Error opening '/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/bin/../lib/clang/31001.363/lib/darwin/libmetal_rt_ios.a': No such file or directory!

Diligent Engine: ERROR in PatchShaderMtl() (Archiver_Mtl.mm, 485): Failed to read shader library

Diligent Engine: ERROR: Failed to compile Metal shaders

Diligent Engine: ERROR in Execute() (RenderStatePackager.cpp, 224): Failed to archive graphics pipeline 'xxxxx.vert+xxxxxxx.frag+_BACKEND_VULKAN_HAS_POSITION'.

Diligent Engine: CRITICAL ERROR in main() (main.cpp, 151): Failed to archive

ninja: build stopped: subcommand failed.

Enable ImGui images

ImGui::Image((void *)image_texture, …) does not work at the moment, as only font texture is allowed.

File2Include tool is not built outside of the source tree

It seems Diligent is not building File2String in the binary output folder, but inside the source tree, which sometimes bugs out CMake download project checkout upgrade:

HEAD detached at 15bd593a
Changes not staged for commit:
(use "git add ..." to update what will be committed)
(use "git restore ..." to discard changes in working directory)
modified: BuildTools/File2Include/bin/Linux/File2String

no changes added to commit (use "git add" and/or "git commit -a")

with the following git error during the checkout:

error: Your local changes to the following files would be overwritten by checkout:
BuildTools/File2Include/bin/Linux/File2String
Please commit your changes or stash them before you switch branches.
Aborting

I think a good idea would be to move this binary file to the build output folder.

RenderStateNotationParser: add functions to create states from device

Add set of functions to create actual render states, e.g.:

CreatePipelineStateByName(const Char* Name, IRenderDevice* pDevice, IPipelineState** ppPSO);
CreatePipelineStateByIndex(Uint32 Index, IRenderDevice* pDevice, IPipelineState** ppPSO);

Note that for pipeline states one function should be sufficient for all pipeline state types - the type of the pipeline to create can be determined internally.

Variables defined in RenderStatePackager resource layout but not in the shaders cause run-time crashes

Diligent is asserting / crashing when unpacking a PSO which has a variable set in the .json resource layout which is not present in the shaders:

Diligent Engine: ERROR in ValidatePipelineResourceSignatures() (PipelineStateBase.cpp, 363): Description of graphics PSO 'xxx.vert+xxxx.frag' is invalid: Resource layout contains variable 'InstancedTransforms' that is not present in the implicit resource signatre. Note that PSO_CREATE_FLAG_IMPLICIT_SIGNATURE0 flag is for internal use only. If you see this message while unpacking PSO from the archive, this might indicate a bug.
Diligent Engine: ERROR in CreateDeviceObject() (RenderDeviceBase.hpp, 511): Failed to create Pipeline State object 'xxxx.vert+xxxx.frag'

RenderStateNotationParser: improve error messages when unexpected value is found

Currently, if JSON contains an incorrect value, the parser silently ignores it and uses the default value, e.g. for the following JSON:

  "DepthStencilDesc": {
      "DepthFunc": "LESS_EQUALblabla",
      "DepthWriteEnable": false
  }

The output will be:

Diligent Engine: ERROR in ValidateDepthStencilDesc() (PipelineStateBase.cpp, 58): Description of graphics PSO 'skybox.vert+skybox.frag+_BACKEND_VULKAN_HAS_POSITION' is invalid: DepthStencilDesc.DepthFunc must not be COMPARISON_FUNC_UNKNOWN when depth is enabled.
Diligent Engine: ERROR in Execute() (RenderStatePackager.cpp, 224): Failed to archive graphics pipeline 'skybox.vert+skybox.frag+_BACKEND_VULKAN_HAS_POSITION'.
Diligent Engine: CRITICAL ERROR in main() (main.cpp, 151): Failed to archive

The parser should print a message about the member and incorrect value.

Add unit tests for parsing errors.

Make sure that #87 is covered

Render State Packager Tasks

  • Rename IDeviceObjectDescriptorParser to IRenderStateNotationParser. Rename associated files and project. No need to name the project Lib as it will be different from RenderStatePackager
  • Replace JSON suffix with RSN (render state notation), e.g. GraphicsPipelineDescJSON -> GraphicsPipelineDescRSN
    • Move original struct descriptors into the RSN structs, e.g.
  struct GraphicsPipelineDescRSN
  {
      GraphicsPipelineDesc Desc;
      const char* pRenderPassName;
  }

In case of GraphicsPipelineDescRSN it may be better to derive it from GraphicsPipelineDesc.

  • Rework enumeration API:
    • Add RenderStateNotationPasrserInfo:
    struct RenderStateNotationPasrserInfo
    {
        Uint32 ShaderCount;
        Uint32 RenderPassCount;
    ...
    };
    • Add IRenderStateNotationParser::GetInfo() method
  • Remove ISerializationDeviceDescriptorParser interface. Move serialization device parsing to the render packager tool. Return null if the index of out bounds.
  • Add basic comments
  • Make sure that RenderStateNotationParser builds on all platforms
  • Add description of the configuration file to the readme
  • Add SPIRV->MSL conversion parsing hook
  • Implement multi-threaded PSO creation
  • Add source files to format validation scripts
  • Remove -Wno-return-type
  • Add static asserts for remaining struct sizes (b8fd22d)

GLTF Model position data should reside in a separate vertex buffer.

The GLTFRenderer is a forward renderer without a depth prepass. This leads to possible overdraw when the multiple models are drawn.
In order to add a depth prepass, 2 additional shaders are needed. The vertex shader of the depth prepass only the vertex position and does not care about any other data(like normals or texture coordinates).
The current implementation of the GLTFModel provides a vertex buffer where position is combined with other data. Using this buffer for the depth prepass vertex shader would be possible, but inefficient.

Render state parser crashes if PipelineType is not specified

If PipelineType parameter is not specified in a json file, the parser crashes.

The parser must never crash if json file is invalid. It should print the error and exit gracefully.

Besides, PipelineType may be automatically deduced from other members of the filed: if there is a GraphicsPipeline member, pVS, pPS, etc. - the pipeline type is clearly graphics.
Similar with compute and ray tracing pipeline.

This must be covered in tests.

RenderStatePackager: add option to output dependency file for shaders

glslang should have an option to output dependency file for includes after unrolling all macros. If it is the case, we should add an option to RenderStatePackager to output dependency files for all shaders in the json file.
The tool should take a shader depenency directory as command line option and write dependency files in this directory.

Potential bug when parallel building using RenderStatePackager?

When running RenderStatePackager in parallel using Ninja, we're getting the message "Waiting to acquire lock to write file Shader.metallib" - I think this might be a bug in Diligent where it writes to one and the same file, instead of creating a temporary files in the /tmp folder?

When I force Ninja to use only one thread, this message disappears.

The log looks like this:

Waiting to acquire lock to write file Shader.metallib
Waiting to acquire lock to write file Shader.metallib
Waiting to acquire lock to write file Shader.metallib
Waiting to acquire lock to write file Shader.metallib
Diligent Engine: ERROR in PatchShaderMtl() (Archiver_Mtl.mm, 485): Failed to read shader library

Diligent Engine: ERROR: Failed to compile Metal shaders

Diligent Engine: ERROR in Execute() (RenderStatePackager.cpp, 224): Failed to archive graphics pipeline 'xxxx.vert+xxxx.frag'.

Diligent Engine: CRITICAL ERROR in main() (main.cpp, 151): Failed to archive

Make ImGUI path configurable?

Hi,

I wanted to know if that would be possible to make the ImGUI path configurable as a CMake option for DiligentTools. This would help us to use a custom ImGUI build while avoid doing a fork just for that.

For now, it. seems it's hardcoded in DiligentTools/ImGui/CMakeLists.txt as follow:

set(DEAR_IMGUI_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../ThirdParty/imgui")

Thanks!

export IPHONEOS_DEPLOYMENT_TARGET=11 breaks RenderStatePackager

If you set environment variable IPHONEOS_DEPLOYMENT_TARGET to 11 by using:

export IPHONEOS_DEPLOYMENT_TARGET=11

and then run RenderStatePackager, the compilation process always fails with:

metal: warning: using sysroot for 'MacOSX' but targeting 'iPhone' [-Wincompatible-sysroot]
LLVM ERROR: Error opening '/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/metal/macos/bin/../lib/clang/31001.363/lib/darwin/libmetal_rt_ios.a': No such file or directory!
Diligent Engine: ERROR in PatchShaderMtl() (Archiver_Mtl.mm, 485): Failed to read shader library

Diligent Engine: ERROR: Failed to compile Metal shaders

Diligent Engine: ERROR in Execute() (RenderStatePackager.cpp, 224): Failed to archive graphics pipeline 'xxxx.vert+xxxx.frag'.

Diligent Engine: CRITICAL ERROR in main() (main.cpp, 151): Failed to archive

This is a problem for us as we have to build for the deployment target 11 and XCode sets this variable as part of the environment for executing custom defined scripts (ie. shader building).

Removing the deployment target environment variable with:

unset IPHONEOS_DEPLOYMENT_TARGET

fixed the problem, but likely compiles the shaders for the wrong deployment target.

RenderStateNotation: add option to import other json files

For example:

{
    "Imports": [
        "path1",
        "path2"
    ]
}

CreateRenderStateNotationParserFromFile and CreateRenderStateNotationParserFromString should be replaced with

CreateRenderStateNotationParser(const RenderStateNotationParserCreateInfo& CreateInfo)
struct RenderStateNotationParserCreateInfo
{
     const Char* FilePath;
     const Char* StrData;
     IShaderSourceInputStreamFactory* pStreamFactory;
};

pStreamFactory will be used to recursively load imported json files

RenderStatePackager crash

Diligent Engine: ERROR in ValidatePipelineStateArchiveInfo() (ArchiverImpl.cpp, 770): Description of PSO is invalid: At least one bit must be set in DeviceFlags
Diligent Engine: ERROR: Debug assertion failed in GetCurrentSize(), file FixedLinearAllocator.hpp, line 349:
Memory has not been allocated
Trace/breakpoint trap (core dumped)

Also the tool seems to be crashing if I put in a wrong file path (notice the segmentation fault at the end):

Diligent Engine: ERROR in CreateInputStream2() (DefaultShaderSourceStreamFactory.cpp, 120): Failed to create input stream for source file post_process_generic.vert_BACKEND_VULKAN_HAS_POSITION_HAS_UV_USE_SUBPASS_INPUT_COLOR2.pre_processed2
Segmentation fault (core dumped)

After the errors, the tool leaves the Archive.bin file with 0 bytes written out to the same folder.

Can't build Diligent Tools

  • OS Ubuntu 20.04
  • Build tools gcc 10.3.0-1ubuntu1

I have performed the following commands:

git clone [email protected]:DiligentGraphics/DiligentTools.git
cd DiligentTools
git submodule update --init
cmake -S . -B ./build/Linux64 -G "Unix Makefiles" -DCMAKE_BUILD_TYPE="Debug"

I've got the following output:
CMake Warning (dev) in CMakeLists.txt:
No project() command is present. The top-level CMakeLists.txt file must
contain a literal, direct call to the project() command. Add a line of
code such as

project(ProjectName)

near the top of the file, but after cmake_minimum_required().

CMake is pretending there is a "project(Project)" command on the first
line.
This warning is for project developers. Use -Wno-dev to suppress it.

-- The C compiler identification is GNU 10.3.0
-- The CXX compiler identification is GNU 10.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Error at ThirdParty/libjpeg-9a/CMakeLists.txt:67 (set_common_target_properties):
Unknown CMake command "set_common_target_properties".

-- Configuring incomplete, errors occurred!
See also "/home/andrei/sources/DiligentTools/build/Linux64/CMakeFiles/CMakeOutput.log".

Refactor IRenderStateNotationParser

In current implementation render state notation parser extracts state descriptions only, which requires extra effort from the application. It also introduces a lot of additional structs that largely duplicate core structs with only difference that instead of object pointers they use object names (e.g. pVS vs pVSName).
To make the render state notion API more convenient to use it is proposed to change the API as follows:

  • Add pDevice member to RenderStateNotationParserCreateInfo
    • This could be a serialization device or any actual rendering device
  • Add DeviceBits member that will only be used for archiver
  • Replace all current methods Get*ByName and Get*ByIndex with Create and Create*ByIndex
  • To make object creation more flexible, add callbacks to override the state:
struct ParsePipelineStateAttribs
{
    const char* Name = nullptr;
    Uint32 Index   = ~0u;

    void (*ModifyPipelineStateCreateInfo)(PipelineStateCreateInfo REF PipelineCI, void* pUserData) = nullptr;
};

VIRTUAL void METHOD(ParsePipelineState)(THIS_
                                        const ParsePipelineStateAttribs REF Attribs,
                                        IPipelineState* ppPSO) CONST PURE;

Similar for other object types.

This should make the parser API much more concise and convenient to use - API objects can be created directly, while required states can be easily overriden

Add option to redirect diligent error messages

It would be great if I could redirect the log messages generated by Diligent, so that we could integrate it with our logging system. A simple callback would suffice.

Also, errors in shaders shouldn't display a blocking message box on Win32. Again, a callback or return value with error description would be better.

Fix compiler warnings in RenderStatePackager

RenderStatePackager target is not linked with Diligent-BuildSettings that sets the warnings-as-errors compile option. As a result, there are some compiler warnings that should ne fixed.

Improve messages about json parsing errors

The tool now prints the following error which does not tell which file exactly caused the problem:

terminate called after throwing an instance of 'nlohmann::detail::parse_error'
  what():  [json.exception.parse_error.101] parse error at line 62, column 13: syntax error while parsing value - unexpected ']'; expected '[', '{', or a literal
terminate called recursively
Aborted (core dumped)
ninja: build stopped: subcommand failed.
ninja: build stopped: subcommand failed.

An error message should be clear about which file exactly failed to parse.

RenderStatePackager release mode only problem

On Linux, when compiled in release mode, RenderStatePackager fails with the below error message, while when compiled in debug mode it works just fine.

The repro case for this one was provided via email due to the material under NDA which it includes.

Unable to parse built-ins
ERROR: 0:1: '' : array size must be a positive integer
ERROR: 0:1: '' : compilation terminated
INTERNAL ERROR: Unable to parse built-ins

const mediump int gl_MaxVertexAttribs = 64;const mediump int gl_MaxVertexUniformVectors = 128;const mediump int gl_MaxVertexTextureImageUnits = 32;const mediump int gl_MaxCombinedTextureImageUnits = 80;const mediump int gl_MaxTextureImageUnits = 32;const mediump int gl_MaxFragmentUniformVectors = 16;const mediump int gl_MaxDrawBuffers = 32;const mediump int gl_MaxVertexOutputVectors = 16;const mediump int gl_MaxFragmentInputVectors = 15;const mediump int gl_MinProgramTexelOffset = -8;const mediump int gl_MaxProgramTexelOffset = 7;const int gl_MaxGeometryInputComponents = 64;const int gl_MaxGeometryOutputComponents = 128;const int gl_MaxGeometryImageUniforms = 0;const int gl_MaxGeometryTextureImageUnits = 16;const int gl_MaxGeometryOutputVertices = 256;const int gl_MaxGeometryTotalOutputComponents = 1024;const int gl_MaxGeometryUniformComponents = 1024;const int gl_MaxGeometryAtomicCounters = 0;const int gl_MaxGeometryAtomicCounterBuffers = 0;const int gl_MaxTessControlInputComponents = 128;const int gl_MaxTessControlOutputComponents = 128;const int gl_MaxTessControlTextureImageUnits = 16;const int gl_MaxTessControlUniformComponents = 1024;const int gl_MaxTessControlTotalOutputComponents = 4096;const int gl_MaxTessEvaluationInputComponents = 128;const int gl_MaxTessEvaluationOutputComponents = 128;const int gl_MaxTessEvaluationTextureImageUnits = 16;const int gl_MaxTessEvaluationUniformComponents = 1024;const int gl_MaxTessPatchComponents = 120;const int gl_MaxPatchVertices = 32;const int gl_MaxTessGenLevel = 64;const int gl_MaxTessControlImageUniforms = 0;const int gl_MaxTessEvaluationImageUniforms = 0;const int gl_MaxTessControlAtomicCounters = 0;const int gl_MaxTessEvaluationAtomicCounters = 0;const int gl_MaxTessControlAtomicCounterBuffers = 0;const int gl_MaxTessEvaluationAtomicCounterBuffers = 0;const mediump int gl_MaxDualSourceDrawBuffersEXT = 0;mediump vec4 gl_SecondaryFragColorEXT;mediump vec4 gl_SecondaryFragDataEXT[gl_MaxDualSourceDrawBuffersEXT];
const ivec3 gl_MaxComputeWorkGroupCount = ivec3(65535,65535,65535);const ivec3 gl_MaxComputeWorkGroupSize = ivec3(1024,1024,64);const int gl_MaxComputeUniformComponents = 1024;const int gl_MaxComputeTextureImageUnits = 16;
const int gl_MaxImageUnits = 8;const int gl_MaxCombinedShaderOutputResources = 8;const int gl_MaxVertexImageUniforms = 0;const int gl_MaxFragmentImageUniforms = 8;const int gl_MaxCombinedImageUniforms = 8;const int gl_MaxComputeImageUniforms = 8;const int gl_MaxComputeAtomicCounters = 8;const int gl_MaxComputeAtomicCounterBuffers = 1;
const int gl_MaxVertexAtomicCounters = 0;const int gl_MaxFragmentAtomicCounters = 8;const int gl_MaxCombinedAtomicCounters = 8;const int gl_MaxAtomicCounterBindings = 1;const int gl_MaxVertexAtomicCounterBuffers = 0;const int gl_MaxFragmentAtomicCounterBuffers = 1;const int gl_MaxCombinedAtomicCounterBuffers = 1;const int gl_MaxAtomicCounterBufferSize = 16384;const int gl_MaxSamples = 4;const int gl_MaxMeshOutputVerticesNV = 256;const int gl_MaxMeshOutputPrimitivesNV = 512;const ivec3 gl_MaxMeshWorkGroupSizeNV = ivec3(32,1,1);const ivec3 gl_MaxTaskWorkGroupSizeNV = ivec3(32,1,1);const int gl_MaxMeshViewCountNV = 4;

Unable to parse built-ins
ERROR: 0:1: '' : array size must be a positive integer
ERROR: 0:1: '' : compilation terminated
INTERNAL ERROR: Unable to parse built-ins

const mediump int gl_MaxVertexAttribs = 64;const mediump int gl_MaxVertexUniformVectors = 128;const mediump int gl_MaxVertexTextureImageUnits = 32;const mediump int gl_MaxCombinedTextureImageUnits = 80;const mediump int gl_MaxTextureImageUnits = 32;const mediump int gl_MaxFragmentUniformVectors = 16;const mediump int gl_MaxDrawBuffers = 32;const mediump int gl_MaxVertexOutputVectors = 16;const mediump int gl_MaxFragmentInputVectors = 15;const mediump int gl_MinProgramTexelOffset = -8;const mediump int gl_MaxProgramTexelOffset = 7;const int gl_MaxGeometryInputComponents = 64;const int gl_MaxGeometryOutputComponents = 128;const int gl_MaxGeometryImageUniforms = 0;const int gl_MaxGeometryTextureImageUnits = 16;const int gl_MaxGeometryOutputVertices = 256;const int gl_MaxGeometryTotalOutputComponents = 1024;const int gl_MaxGeometryUniformComponents = 1024;const int gl_MaxGeometryAtomicCounters = 0;const int gl_MaxGeometryAtomicCounterBuffers = 0;const int gl_MaxTessControlInputComponents = 128;const int gl_MaxTessControlOutputComponents = 128;const int gl_MaxTessControlTextureImageUnits = 16;const int gl_MaxTessControlUniformComponents = 1024;const int gl_MaxTessControlTotalOutputComponents = 4096;const int gl_MaxTessEvaluationInputComponents = 128;const int gl_MaxTessEvaluationOutputComponents = 128;const int gl_MaxTessEvaluationTextureImageUnits = 16;const int gl_MaxTessEvaluationUniformComponents = 1024;const int gl_MaxTessPatchComponents = 120;const int gl_MaxPatchVertices = 32;const int gl_MaxTessGenLevel = 64;const int gl_MaxTessControlImageUniforms = 0;const int gl_MaxTessEvaluationImageUniforms = 0;const int gl_MaxTessControlAtomicCounters = 0;const int gl_MaxTessEvaluationAtomicCounters = 0;const int gl_MaxTessControlAtomicCounterBuffers = 0;const int gl_MaxTessEvaluationAtomicCounterBuffers = 0;const mediump int gl_MaxDualSourceDrawBuffersEXT = 0;mediump vec4 gl_SecondaryFragColorEXT;mediump vec4 gl_SecondaryFragDataEXT[gl_MaxDualSourceDrawBuffersEXT];
const ivec3 gl_MaxComputeWorkGroupCount = ivec3(65535,65535,65535);const ivec3 gl_MaxComputeWorkGroupSize = ivec3(1024,1024,64);const int gl_MaxComputeUniformComponents = 1024;const int gl_MaxComputeTextureImageUnits = 16;
const int gl_MaxImageUnits = 8;const int gl_MaxCombinedShaderOutputResources = 8;const int gl_MaxVertexImageUniforms = 0;const int gl_MaxFragmentImageUniforms = 8;const int gl_MaxCombinedImageUniforms = 8;const int gl_MaxComputeImageUniforms = 8;const int gl_MaxComputeAtomicCounters = 8;const int gl_MaxComputeAtomicCounterBuffers = 1;
const int gl_MaxVertexAtomicCounters = 0;const int gl_MaxFragmentAtomicCounters = 8;const int gl_MaxCombinedAtomicCounters = 8;const int gl_MaxAtomicCounterBindings = 1;const int gl_MaxVertexAtomicCounterBuffers = 0;const int gl_MaxFragmentAtomicCounterBuffers = 1;const int gl_MaxCombinedAtomicCounterBuffers = 1;const int gl_MaxAtomicCounterBufferSize = 16384;const int gl_MaxSamples = 4;const int gl_MaxMeshOutputVerticesNV = 256;const int gl_MaxMeshOutputPrimitivesNV = 512;const ivec3 gl_MaxMeshWorkGroupSizeNV = ivec3(32,1,1);const ivec3 gl_MaxTaskWorkGroupSizeNV = ivec3(32,1,1);const int gl_MaxMeshViewCountNV = 4;

RenderStatePacker crashes with empty argument list

The tool crashes when executed without arguments. Expected behavior: print argument list

Diligent Engine: ERROR: Debug assertion failed in GetCurrentSize(), file FixedLinearAllocator.hpp, line 349:
Memory has not been allocated
Trace/breakpoint trap (core dumped)

OS: Ubuntu / Linux

Missing include in ImGuiImplLinuxX11.hpp

It seems that the file ImGuiImplLinuxX11.hpp misses the following include

#include <X11/Xlib.h>

If I include the ImGuiImplLinuxX11.hpp file, compilation shows me this error:

In file included from /home/.../Application.cc:9:
/.../DiligentTools/Imgui/interface/ImGuiImplLinuxX11.hpp:57:31: error: ‘XEvent’ has not been declared
   57 |     bool         HandleXEvent(XEvent* event);
      |                               ^~~~~~

RenderStateNotationParserCreateInfo should take render state files factory

RenderStateNotationParserCreateInfo has factory for shader stream data, but not for render state notation files.
Both members can be null to allow the parser create default factories.

pStreamFactory should be renamed to pShaderSourceFactory
The new member should be named pNotationSourceFactory

Create Texture from memory or from stream

It would be great if the texture loader component contained functions to create textures not only from files, but also from memory or from user streams. It seems the functionality is almost there, but it's not exposed to the end user. Also the image types are deduced from file extensions, rather than from the actual file headers.

Are there docs for the tools?

Hello ;)

I wanted to ask, if there is any documentation available on how to use i.e. AppBase?
Couldn't find any.

Greetings.

DiligentTools generated files are not generated in the output binary folder

Similar to the File2String tool, generated files are stored in the source tree instead of the binary tree:

error: Your local changes to the following files would be overwritten by checkout:
RenderStateNotationParser/generated/BlendStateParser.hpp
RenderStateNotationParser/generated/CommonParser.hpp
RenderStateNotationParser/generated/DepthStencilStateParser.hpp
RenderStateNotationParser/generated/GraphicsTypesParser.hpp
RenderStateNotationParser/generated/InputLayoutParser.hpp
RenderStateNotationParser/generated/PipelineResourceSignatureParser.hpp
RenderStateNotationParser/generated/PipelineStateParser.hpp
RenderStateNotationParser/generated/RasterizerStateParser.hpp
RenderStateNotationParser/generated/RenderPassParser.hpp
RenderStateNotationParser/generated/SamplerParser.hpp
RenderStateNotationParser/generated/SerializationDeviceParser.hpp
RenderStateNotationParser/generated/ShaderParser.hpp
RenderStateNotationParser/generated/ShaderResourceVariableParser.hpp
Please commit your changes or stash them before you switch branches.
Aborting
CMake Error at /xxxx/3rdparty/.cache/DiligentTools/DiligentTools-download-prefix/tmp/DiligentTools-download-gitupdate.cmake:201 (message):
Failed to checkout tag: 'f32158c73955aac5db1b1a8cec821fedaf34555d'

This makes upgrading to latest Diligent problematic and requires manual steps.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.