Page 1 of 2

DirectX 12 custom engine questions

Posted: 09 Feb 2026, 22:27
by arkaen
Hello again,

I've been experimenting with a custom DirectX 12 mini-engine and I've gotten most Noesis features integrated into it nicely. But I suddenly ran into problems as soon as I tried to use a drop-shadow effect on a control (Button). As soon as I mouse over the button and trigger that state (which uses the effect), I get spammed with a bunch of error/warning messages from the SDK debug layer and the whole NoesisGUI view flickers and disappears:
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Draw: Resource 0x0000019B5B7449C0:'Unnamed ID3D12Resource Object', subresource [0] is pending an incomplete split barrier. This is used as a render target [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Draw: Resource 0x0000019B5B7449C0:'Unnamed ID3D12Resource Object', subresource [0] is pending an incomplete split barrier. This is used as a render target [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Draw: Resource 0x0000019B5B7449C0:'Unnamed ID3D12Resource Object', subresource [0] is pending an incomplete split barrier. This is used as a render target [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Using Draw on Command List (0x0000019B538716F0:'Unnamed ID3D12GraphicsCommandList Object'): Resource state (0x80: D3D12_RESOURCE_STATE_PIXEL_SHADER_RESOURCE) of resource (0x0000019B5B7449C0:'Unnamed ID3D12Resource Object') (subresource: 0) is invalid for use as a render target. Expected State Bits (all): 0x4: D3D12_RESOURCE_STATE_RENDER_TARGET, Actual State: 0x80: D3D12_RESOURCE_STATE_PIXEL_SHADER_RESOURCE, Missing State: 0x4: D3D12_RESOURCE_STATE_RENDER_TARGET. [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandQueue1::ExecuteCommandLists: Placed resources, reserved resources, or committed resources with D3D12_HEAP_FLAG_CREATE_NOT_ZEROED flag with either render target or depth stencil flags must be initialized with a Discard/Clear/Copy operations before other operations are supported. Resource (0x0000019B5B747C00:'Unnamed ID3D12Resource Object'), Subresource (0) is not initialized but is used in Function (ID3D12CommandList::DrawIndexedInstanced) on Command List (0x0000019B708DC5F0:'CommandList'). [ EXECUTION ERROR #1422: RENDER_TARGET_OR_DEPTH_STENCIL_RESOUCE_NOT_INITIALIZED]
D3D12 ERROR: ID3D12CommandQueue1::ExecuteCommandLists: Placed resources, reserved resources, or committed resources with D3D12_HEAP_FLAG_CREATE_NOT_ZEROED flag with either render target or depth stencil flags must be initialized with a Discard/Clear/Copy operations before other operations are supported. Resource (0x0000019B5B740AF0:'Unnamed ID3D12Resource Object'), Subresource (0) is not initialized but is used in Function (ID3D12CommandList::DrawIndexedInstanced) on Command List (0x0000019B708DC5F0:'CommandList'). [ EXECUTION ERROR #1422: RENDER_TARGET_OR_DEPTH_STENCIL_RESOUCE_NOT_INITIALIZED]
D3D12 ERROR: ID3D12CommandQueue1::ExecuteCommandLists: Placed resources, reserved resources, or committed resources with D3D12_HEAP_FLAG_CREATE_NOT_ZEROED flag with either render target or depth stencil flags must be initialized with a Discard/Clear/Copy operations before other operations are supported. Resource (0x0000019B5B741780:'Unnamed ID3D12Resource Object'), Subresource (0) is not initialized but is used in Function (ID3D12CommandList::DrawIndexedInstanced) on Command List (0x0000019B708DC5F0:'CommandList'). [ EXECUTION ERROR #1422: RENDER_TARGET_OR_DEPTH_STENCIL_RESOUCE_NOT_INITIALIZED]
D3D12 ERROR: ID3D12CommandQueue1::ExecuteCommandLists: Placed resources, reserved resources, or committed resources with D3D12_HEAP_FLAG_CREATE_NOT_ZEROED flag with either render target or depth stencil flags must be initialized with a Discard/Clear/Copy operations before other operations are supported. Resource (0x0000019B5B743D30:'Unnamed ID3D12Resource Object'), Subresource (1) is not initialized but is used in Function (ID3D12CommandList::DrawIndexedInstanced) on Command List (0x0000019B708DC5F0:'CommandList'). [ EXECUTION ERROR #1422: RENDER_TARGET_OR_DEPTH_STENCIL_RESOUCE_NOT_INITIALIZED]
D3D12 ERROR: ID3D12CommandQueue1::ExecuteCommandLists: Placed resources, reserved resources, or committed resources with D3D12_HEAP_FLAG_CREATE_NOT_ZEROED flag with either render target or depth stencil flags must be initialized with a Discard/Clear/Copy operations before other operations are supported. Resource (0x0000019B5B748890:'Unnamed ID3D12Resource Object'), Subresource (0) is not initialized but is used in Function (ID3D12CommandList::DrawIndexedInstanced) on Command List (0x0000019B708DC5F0:'CommandList'). [ EXECUTION ERROR #1422: RENDER_TARGET_OR_DEPTH_STENCIL_RESOUCE_NOT_INITIALIZED]
D3D12 ERROR: ID3D12CommandQueue1::ExecuteCommandLists: Placed resources, reserved resources, or committed resources with D3D12_HEAP_FLAG_CREATE_NOT_ZEROED flag with either render target or depth stencil flags must be initialized with a Discard/Clear/Copy operations before other operations are supported. Resource (0x0000019B5B7430A0:'Unnamed ID3D12Resource Object'), Subresource (0) is not initialized but is used in Function (ID3D12CommandList::DrawIndexedInstanced) on Command List (0x0000019B708DC5F0:'CommandList'). [ EXECUTION ERROR #1422: RENDER_TARGET_OR_DEPTH_STENCIL_RESOUCE_NOT_INITIALIZED]
D3D12 ERROR: ID3D12CommandQueue1::ExecuteCommandLists: Placed resources, reserved resources, or committed resources with D3D12_HEAP_FLAG_CREATE_NOT_ZEROED flag with either render target or depth stencil flags must be initialized with a Discard/Clear/Copy operations before other operations are supported. Resource (0x0000019B5B7449C0:'Unnamed ID3D12Resource Object'), Subresource (0) is not initialized but is used in Function (ID3D12CommandList::DrawIndexedInstanced) on Command List (0x0000019B708DC5F0:'CommandList'). [ EXECUTION ERROR #1422: RENDER_TARGET_OR_DEPTH_STENCIL_RESOUCE_NOT_INITIALIZED]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Draw: Resource 0x0000019B5B7449C0:'Unnamed ID3D12Resource Object', subresource [0] is pending an incomplete split barrier. This is used as a render target [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Draw: Resource 0x0000019B5B7449C0:'Unnamed ID3D12Resource Object', subresource [0] is pending an incomplete split barrier. This is used as a render target [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Draw: Resource 0x0000019B5B7449C0:'Unnamed ID3D12Resource Object', subresource [0] is pending an incomplete split barrier. This is used as a render target [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Using Draw on Command List (0x0000019B5B77D040:'Unnamed ID3D12GraphicsCommandList Object'): Resource state (0x80: D3D12_RESOURCE_STATE_PIXEL_SHADER_RESOURCE) of resource (0x0000019B5B7449C0:'Unnamed ID3D12Resource Object') (subresource: 0) is invalid for use as a render target. Expected State Bits (all): 0x4: D3D12_RESOURCE_STATE_RENDER_TARGET, Actual State: 0x80: D3D12_RESOURCE_STATE_PIXEL_SHADER_RESOURCE, Missing State: 0x4: D3D12_RESOURCE_STATE_RENDER_TARGET. [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Draw: Resource 0x0000019B5B7449C0:'Unnamed ID3D12Resource Object', subresource [0] is pending an incomplete split barrier. This is used as a render target [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Draw: Resource 0x0000019B5B7449C0:'Unnamed ID3D12Resource Object', subresource [0] is pending an incomplete split barrier. This is used as a render target [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Draw: Resource 0x0000019B5B7449C0:'Unnamed ID3D12Resource Object', subresource [0] is pending an incomplete split barrier. This is used as a render target [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
It seems like I've got an issue where an off-screen texture resource is being used as render target and pixel shader resource at the same time and there are some split resource barriers not being handled properly. I threw all of this together pretty quickly using code from the Native SDK's NoesisApp source and putting it into a static library project alongside my actual application. What I'm not so sure about is if the problem is just the usage of this code or if it has a bug or some kind of fundamental conflict with the mini-engine (custom version of the one from DirectX 12 samples).

The last rendering function I was trying:

    void ArkaenNoesisHost::Render( GraphicsContext& ctx ) {
        if( !m_view || !m_renderDevice ) return ;

        // Make sure any engine barriers are flushed before giving the list to Noesis
        //ctx.FlushResourceBarriers( ) ;

        ID3D12GraphicsCommandList* cmd = ctx.GetCommandList( ) ;
        uint64_t fenceValue = Graphics::g_CommandManager.GetGraphicsQueue( ).GetNextFenceValue( ) ;
        NoesisApp::D3D12Factory::SetCommandList( m_renderDevice, cmd, fenceValue+1 ) ;

        auto* r = m_view->GetRenderer( ) ;
        r->SetRenderRegion( 0, 0, (float)m_width, (float)m_height ) ;
        r->UpdateRenderTree( ) ;
        r->RenderOffscreen( ) ;
        r->Render( false, false ) ;

        //NoesisApp::D3D12Factory::EndPendingSplitBarriers( m_renderDevice ) ;

        // CRITICAL: Noesis mutated heaps/PSO/rootsig on the raw command list.
        // Your engine wrapper MUST invalidate its caches or it will "think" the old heaps are still bound.
        ctx.InvalidateCachedState( ) ;
    }
The engine does this and triggers the UI/Noesis rendering logic after drawing the "main scene":

    static bool UpdateApplication( IGameApp& game ) {
        EngineProfiling::Update( ) ;
        float DeltaTime = Graphics::GetFrameTime( ) ;
    
        GameInput::Update( DeltaTime ) ;
        EngineTuning::Update( DeltaTime ) ;
        
        game.Update( DeltaTime ) ;
        game.RenderScene( ) ;

        PostEffects::Render( ) ;

        GraphicsContext& UiContext = GraphicsContext::Begin( L"Render UI" ) ;
        UiContext.TransitionResource( g_OverlayBuffer, D3D12_RESOURCE_STATE_RENDER_TARGET, true ) ;
        UiContext.ClearColor( g_OverlayBuffer ) ;
        UiContext.SetRenderTarget( g_OverlayBuffer.GetRTV() ) ;
        UiContext.SetViewportAndScissor( 0, 0, g_OverlayBuffer.GetWidth(), g_OverlayBuffer.GetHeight() ) ;
        game.RenderUI( UiContext ) ;

        UiContext.SetRenderTarget( g_OverlayBuffer.GetRTV() ) ;
        UiContext.SetViewportAndScissor( 0, 0, g_OverlayBuffer.GetWidth(), g_OverlayBuffer.GetHeight() ) ;
        EngineTuning::Display( UiContext, 10.0f, 40.0f, 1900.0f, 1040.0f ) ;

        UiContext.Finish( ) ;
        Display::Present( ) ;
        return !game.IsDone( ) ;
    }
    
Yes, I've been trying some different things and commenting things out and making a bit of mess here, lol. But I figured before I plunge into that huge 3,000+ line .cpp file D3D12RenderDevice I would ask a few questions and get some clarifications that might save me some considerable time and trouble.

Am I making any obvious mistakes in how I'm attempting to render/use things? Should I use the "render context" instead of the raw "render device" code? Or should I possibly just use the whole NoesisApp source code as-is? And any ideas on what's going wrong here and how I'm getting these invalid states and resource barrier issues? The problem only occurs when I use that drop-shadow effect, so it has to do with this and the pixel shader and how resources are handled.

I'm also curious what I would need to do to integrate with Noesis Studio and accomplish things like having my custom components/views show up ... basically, just a high-level overview of what I need to do to make a small integration for my engine similar to the ones from Unity and Unreal and how that's accomplished.

Lately, I've experimented with NoesisGUI in Unreal, Unity and native DirectX 12 and it's been quite fun and rewarding! I have some findings and suggestions/improvements for all 3 I intend to share with you guys soon, and if time allows I'll try to make some YouTube videos or something about this. This native DirectX 12 engine/app project is for experimenting with a 4x "grand strategy" style of game set during the decline/collapse of the Roman Empire and the Great Migration period. As I've been working on this, I'm simultaneously working on the 3D campaign map in Houdini, and I expect it's going to be quite a spectacle, haha. :D

Regards,

Aaron

Re: DirectX 12 custom engine questions

Posted: 10 Feb 2026, 00:27
by jsantos
Am I making any obvious mistakes in how I'm attempting to render/use things? Should I use the "render context" instead of the raw "render device" code? Or should I possibly just use the whole NoesisApp source code as-is? And any ideas on what's going wrong here and how I'm getting these invalid states and resource barrier issues? The problem only occurs when I use that drop-shadow effect, so it has to do with this and the pixel shader and how resources are handled.
My first question about this would be whether you are able to reproduce the issue using our XamlPlayer (making sure it is running with our D3D12 renderer, which is the default).
I'm also curious what I would need to do to integrate with Noesis Studio and accomplish things like having my custom components/views show up ... basically, just a high-level overview of what I need to do to make a small integration for my engine similar to the ones from Unity and Unreal and how that's accomplished.
We are currently preparing the first C++ SDK with Studio integration. As part of that release, we are going to provide the full source code of a Studio integration (our official StudioTool). You’ll be able to see that Studio is integrated in exactly the same way as the standard samples. There are no fundamental differences in terms of architecture, everything is ultimately based on creating a View and rendering it into a window.
Lately, I've experimented with NoesisGUI in Unreal, Unity and native DirectX 12 and it's been quite fun and rewarding! I have some findings and suggestions/improvements for all 3 I intend to share with you guys soon, and if time allows I'll try to make some YouTube videos or something about this. This native DirectX 12 engine/app project is for experimenting with a 4x "grand strategy" style of game set during the decline/collapse of the Roman Empire and the Great Migration period. As I've been working on this, I'm simultaneously working on the 3D campaign map in Houdini, and I expect it's going to be quite a spectacle, haha. :D
Please keep us posted about your experiments, it’s great to hear that you’ve been exploring NoesisGUI across Unreal, Unity, and native DirectX 12. Feedback from real-world experimentation like this is extremely valuable to us, especially when it spans multiple platforms and rendering backends.

Whenever you’re ready, feel free to share your findings, suggestions, or pain points. We’re happy to review them, discuss possible improvements, and fix as many issues as possible where it makes sense.

Re: DirectX 12 custom engine questions

Posted: 10 Feb 2026, 02:23
by arkaen
My first question about this would be whether you are able to reproduce the issue using our XamlPlayer (making sure it is running with our D3D12 renderer, which is the default).
I couldn't really think of any better way to test that than to cram everything into "MainView.xaml" in UserControl.Resources, but it does seem to work fine in the XAML player. I'm having trouble figuring out exactly what my code needs to call and in what order, and how I'm ending up with these state mismatches on an unnamed resource (since I don't fully understand what Noesis does under the hood yet). I added a name to the command list to make sure it's the one I'm passing Noesis, and it is:
D3D12 ERROR: ID3D12CommandList::DrawIndexedInstanced: Using Draw on Command List (0x000001DEFF50D8B0:'Noesis UI Render Command List (debug layer indirect)'): Resource state (0x80: D3D12_RESOURCE_STATE_PIXEL_SHADER_RESOURCE) of resource (0x000001DEFF3044E0:'Unnamed ID3D12Resource Object') (subresource: 0) is invalid for use as a render target. Expected State Bits (all): 0x4: D3D12_RESOURCE_STATE_RENDER_TARGET, Actual State: 0x80: D3D12_RESOURCE_STATE_PIXEL_SHADER_RESOURCE, Missing State: 0x4: D3D12_RESOURCE_STATE_RENDER_TARGET. [ EXECUTION ERROR #538: INVALID_SUBRESOURCE_STATE]
How exactly am I getting into this mismatched state and split barriers situation, and what is the "correct" path (and is a high-level explanation of this possible)? I'm still not sure which call is setting that pixel shader resource state and where should I be transitioning back to render target? I'm not sure if I'm even calling things in the right order (or making all necessary calls) because it's my first time playing with native SDK + D3D12 together. My suspicion is that the drop-shadow effect uses a pixel shader and an off-screen texture as its render target and that's what's causing the confusion and misuse here ...

I've been trying some whacky stuff like inserting calls to "EndPendingSplitBarriers" and so forth to no avail ... so I guess I'm going to have to end up stepping through line by line and doing more rigorous debugging, lol.
void ArkaenNoesisHost::Render( GraphicsContext& ctx ) {
    if( !m_view || !m_renderDevice ) return ;
	const auto cmdListName = L"Noesis UI Render Command List" ;

    ctx.FlushResourceBarriers( ) ;

    ID3D12GraphicsCommandList* cmd = ctx.GetCommandList( ) ;
    cmd->SetName( cmdListName ) ;

    uint64_t fenceValue = Graphics::g_CommandManager.GetGraphicsQueue( ).GetNextFenceValue( ) ;
    NoesisApp::D3D12Factory::SetCommandList( m_renderDevice, cmd, fenceValue+1 ) ;

    auto* r = m_view->GetRenderer( ) ;
    r->SetRenderRegion( 0, 0, (float)m_width, (float)m_height ) ;
    r->UpdateRenderTree( ) ;
    r->RenderOffscreen( ) ;
	m_renderDevice->EndOffscreenRender( ) ;

    NoesisApp::D3D12Factory::EndPendingSplitBarriers( m_renderDevice ) ;

    r->Render( false, false ) ;

    NoesisApp::D3D12Factory::EndPendingSplitBarriers( m_renderDevice ) ;
}
We are currently preparing the first C++ SDK with Studio integration. As part of that release, we are going to provide the full source code of a Studio integration (our official StudioTool). You’ll be able to see that Studio is integrated in exactly the same way as the standard samples. There are no fundamental differences in terms of architecture, everything is ultimately based on creating a View and rendering it into a window.
That is very exciting to hear and I can't wait to see this! Speaking of this, I'm supposed to be using the Native SDK from the usual "Downloads" page up top, right? Is there an open-source example of DirectX 12 app using Noesis I should look at as a "working example" to emulate?
Please keep us posted about your experiments, it’s great to hear that you’ve been exploring NoesisGUI across Unreal, Unity, and native DirectX 12. Feedback from real-world experimentation like this is extremely valuable to us, especially when it spans multiple platforms and rendering backends.

Whenever you’re ready, feel free to share your findings, suggestions, or pain points. We’re happy to review them, discuss possible improvements, and fix as many issues as possible where it makes sense.
One quick thing I can say about my findings in Unity is that we need to have a bit more control over the media player ... I think NoesisMediaPlayer should allow the user to utilize an existing VideoPlayer component in the scene, maybe by marking it with a designated tag.
    public const string NOESIS_MEDIAPLAYER_TAG = "NoesisMediaPlayer" ;
    
    void GetOrCreatePlayer( ) {
        GameObject? existing = GameObject.FindGameObjectWithTag( NOESIS_MEDIAPLAYER_TAG ) ;
        if ( existing ) {
            _gameObject = existing ;
            _videoPlayer = _gameObject.GetComponent< VideoPlayer >( ) ;
            return ;
        }

        _gameObject  = new GameObject( "MediaPlayer" ) ;
        _videoPlayer = _gameObject.AddComponent< VideoPlayer >( ) ;
    }
I actually did this and got it to work, and theoretically this can speed things up and let you preallocate memory. In my case, I was looking to reduce startup time and lag from loading a video clip by having it already "hot" and loaded in the menu scene and it does seem to work. I also had problems with Noesis creating and destroying a GameObject for this, especially when running an asynchronous startup/loading sequence, which kind of forced me into experimenting with this and it seems to have solved my problems. Ideally, I would have the constructor or a method look at the Uri being passed in when a XAML is loaded/parsed and see if it's the same video clip that's already loaded. If not, then it can load it from assets/disk ... if it is, just leave it alone and play it.

A lot of the same logic applies to handling audio, as well. In a "real" game you'll want to have more control over your audio and be able to pipe menu sound effects through your mixers. I noticed that you can't really do this with the Unity integration "as-is" and it also ignores the Volume parameter set in the XAML and just plays everything at 100% volume.

I also cannot seem to find a repo for the Unity integration source. Is that intentional? I'd be willing to help out a bit and submit some PRs for things like this I come across and fix/change.

------------------
P.S. -
Another thing that would be great is if the VS Code language server and even XAML player had a way to set global resources and directories so it can resolve paths properly in real projects for testing and getting correct Intellisense and error-checking info.

Re: DirectX 12 custom engine questions

Posted: 10 Feb 2026, 03:49
by arkaen
I just figured it out ... this works:

    void ArkaenNoesisHost::Render( GraphicsContext& ctx ) {
        if( !m_view || !m_renderDevice ) return ;

        ID3D12GraphicsCommandList* cmd = ctx.GetCommandList( ) ;
        cmd->SetName( L"Noesis CommandList" ) ;

        // Tell Noesis which command list and fence value we are using.
        uint64_t fenceValue = Graphics::g_CommandManager.GetGraphicsQueue( ).GetNextFenceValue( ) ;
        NoesisApp::D3D12Factory::SetCommandList( m_renderDevice, cmd, fenceValue ) ;

        auto* r = m_view->GetRenderer( ) ;
        r->SetRenderRegion( 0, 0, (float)m_width, (float)m_height ) ;
        r->UpdateRenderTree( ) ;
        r->RenderOffscreen( ) ;
        
        //! Now transition and bind render target:
        ctx.TransitionResource( Graphics::g_OverlayBuffer, D3D12_RESOURCE_STATE_RENDER_TARGET, true ) ;
        ctx.ClearColor( Graphics::g_OverlayBuffer ) ;
        ctx.SetRenderTarget( Graphics::g_OverlayBuffer.GetRTV( ) ) ;
        ctx.SetViewportAndScissor( 0, 0, Graphics::g_OverlayBuffer.GetWidth( ),
                                   Graphics::g_OverlayBuffer.GetHeight() ) ;
        
        r->Render( false, false ) ;
    }
Once I got to manually study the code, I noticed it looked like I needed to call RenderOffscreen before I bind my render target. The mini-engine sets the render target before it even called my "ArkaenNoesisHost::Render( GraphicsContext& ctx )" function, thus things got out of sync and whacky. I made some other changes here and there but this is what really fixed it and now the drop-shadow effects work and the UI doesn't disappear or spam D3D12 debug layer error messages.

Only warning/error I get from the debug layer now is:
D3D12 ERROR: ID3D12CommandQueue1::ExecuteCommandLists: Placed resources, reserved resources, or committed resources with D3D12_HEAP_FLAG_CREATE_NOT_ZEROED flag with either render target or depth stencil flags must be initialized with a Discard/Clear/Copy operations before other operations are supported. Resource (0x000002800BE61E80:'Unnamed ID3D12Resource Object'), Subresource (0) is not initialized but is used in Function (ID3D12CommandList::DrawIndexedInstanced) on Command List (0x000002806A219690:'Noesis CommandList'). [ EXECUTION ERROR #1422: RENDER_TARGET_OR_DEPTH_STENCIL_RESOUCE_NOT_INITIALIZED]
I had to make some small changes to D3D12Texture struct and ResolveRenderTarget(...) in D3D12RenderDevice.cpp to achieve this, but I think I'm good now if I figure out that other warning/error about D3D12_HEAP_FLAG_CREATE_NOT_ZEROED ...

---

Edit: Adding screenshot ...

Image

---

Edit: 2/10/26 ::

I've eliminated all warnings/errors from the D3D12 Debug Layer ... D3D12RenderDevice needed some small modifications to initialize non-zeroed textures and provide an optimized clear color (supposedly performs slightly better). If interested, I can share the code snippets ...

Re: DirectX 12 custom engine questions

Posted: 16 Feb 2026, 12:59
by jsantos
I've eliminated all warnings/errors from the D3D12 Debug Layer ... D3D12RenderDevice needed some small modifications to initialize non-zeroed textures and provide an optimized clear color (supposedly performs slightly better). If interested, I can share the code snippets ...
I haven’t been able to reproduce any warnings or errors with our D3D12 reference renderer. Are you able to reproduce this using one of the SDK samples?
That is very exciting to hear and I can't wait to see this! Speaking of this, I'm supposed to be using the Native SDK from the usual "Downloads" page up top, right? Is there an open-source example of DirectX 12 app using Noesis I should look at as a "working example" to emulate?
All our samples work with any renderer. By default, we use D3D12 on Windows, but this can be changed with --renderer GL|Vulkan|D3D11. The source code for the renderer and context is included in the SDK, so you can debug it and set breakpoints to understand exactly how we render a frame
One quick thing I can say about my findings in Unity is that we need to have a bit more control over the media player ... I think NoesisMediaPlayer should allow the user to utilize an existing VideoPlayer component in the scene, maybe by marking it with a designated tag.
This is a good idea. Indeed, almost all studios create their own interactivity for audio and video. The implementation we provide is a basic sample intended for you to extend or fully replace based on your project’s needs
I also cannot seem to find a repo for the Unity integration source. Is that intentional? I'd be willing to help out a bit and submit some PRs for things like this I come across and fix/change.
Yes, we are not using Git for this. However, please feel free to share diffs here (or via a ticket), and we’ll evaluate them.
Another thing that would be great is if the VS Code language server and even XAML player had a way to set global resources and directories so it can resolve paths properly in real projects for testing and getting correct Intellisense and error-checking info.
Yes, this has been requested many times and is on our TODO list.

Thank you!

Re: DirectX 12 custom engine questions

Posted: 17 Feb 2026, 22:01
by arkaen
I haven’t been able to reproduce any warnings or errors with our D3D12 reference renderer. Are you able to reproduce this using one of the SDK samples?
Since then, I seem to have reconciled all the warnings and errors. I haven't had time to try to repro with the samples yet (juggling several widely-scoped experimental projects with multiple engines), but I will look into this as soon as possible. It's very likely that the reference renderer implementation and NoesisApp code was just clashing a bit with my DirectX 12 engine ... it's creating its own window and D3D12 interfaces/resources and the NoesisApp code was also written to do the same things so things needed a bit of reconciliation and harmonization to get along, I think. But I've thus far been able to customize and adapt that code to interact with this mini-engine nicely. :-)
This is a good idea. Indeed, almost all studios create their own interactivity for audio and video. The implementation we provide is a basic sample intended for you to extend or fully replace based on your project’s needs.

Yes, we are not using Git for this. However, please feel free to share diffs here (or via a ticket), and we’ll evaluate them.
Great! When I jump back into Unity I'll iterate on this a bit further and share the changes.
Yes, this has been requested many times and is on our TODO list.
Thank you!
Glad to hear this, and eagerly awaiting those Noesis Studio examples for custom engines! :-)

---

Since my last post things have been working out pretty great, actually. It was pretty easy to create dynamic resources for compute shader render textures and use them to paint controls and apply custom effects and it's really cool! :-)

The only question I can think of right now has to with rendering emojis and glyphs ... why is it that Noesis seems to render emojis in a TextBlock just fine if it's in the XAML, but if it's set by a binding in a view-model I just get ?? chars or gibberish?

For example, if the view-model exposes a const char* property and we assign it "ℹ️", and use "{Binding TheText}" it will draw ?? in the UI ... but

This renders fine:
<TextBlock Text="ℹ️" />

This does not:
<TextBlock Text="{Binding TheText}" />


Example View-Model:
#pragma once
#include <ViewModel.h>
#include <NoesisPCH.h>

namespace LimesFractus::GUI::ViewModels::Controls {
	class HintItemViewModel final: public ArkaenNoesis::MVVM::ViewModelBase {
		OBSERVED_PROP( const char*, Glyph )
		OBSERVED_PROP( const char*, Text )

	public:
		explicit HintItemViewModel( const char* glyph = "",
						const char* text = "" ):
							_Glyph( glyph ), _Text( text ) { SetIsReady( true ) ; }

	private:
		NS_IMPLEMENT_INLINE_REFLECTION( HintItemViewModel, ArkaenNoesis::MVVM::ViewModelBase,
						"LimesFractus.GUI.ViewModels.Controls.HintItemViewModel" ) {
			NsProp( "Glyph", &HintItemViewModel::GetGlyph, &HintItemViewModel::SetGlyph ) ;
			NsProp( "Text", &HintItemViewModel::GetText, &HintItemViewModel::SetText ) ;
		}
	} ;
	ARKAEN_NOESIS_AUTO_COMPONENT( HintItemViewModel )
}
My only guess is that const char* is the wrong thing to use, but Noesis::String also doesn't work, types like const char16_t* or const wchar_t* cause compilation errors for properties and I can't seem to find a way that works and displays the content correctly. What is it I need to do to properly display emojis in text/strings set via the data context binding?

Re: DirectX 12 custom engine questions

Posted: 18 Feb 2026, 01:24
by jsantos
The only question I can think of right now has to with rendering emojis and glyphs ... why is it that Noesis seems to render emojis in a TextBlock just fine if it's in the XAML, but if it's set by a binding in a view-model I just get ?? chars or gibberish?
This is almost always an encoding issue. XAML files are typically saved as UTF-8, which is why emojis render correctly there. When the text comes from the view model, make sure your strings are UTF-8 encoded as well. Once the string is valid UTF-8, emojis will render correctly through bindings too.

Re: DirectX 12 custom engine questions

Posted: 20 Feb 2026, 03:41
by arkaen
This is almost always an encoding issue. XAML files are typically saved as UTF-8, which is why emojis render correctly there. When the text comes from the view model, make sure your strings are UTF-8 encoded as well. Once the string is valid UTF-8, emojis will render correctly through bindings too.
Thanks! The way I managed to fix it was by using Noto Emoji (only seems to work when supplied as StaticResource in XAML) and then use Noesis::Symbol as my property type and initialize it from an std::u8string or something similar. Here's an example in case anyone else comes hunting for the answer to a similar question:
#pragma once
#include <ViewModel.h>

namespace LimesFractus::GUI::ViewModels::Controls {
	class HintItemViewModel final: public ArkaenNoesis::MVVM::ViewModelBase {
		OBSERVED_PROP( Noesis::Symbol, Glyph )
		OBSERVED_PROP( const char*, Text )

	public:
		HintItemViewModel( std::u8string glyph = {}, const char* text = {} ):
							_Glyph( reinterpret_cast<const char *>(glyph.data()) ),
								_Text( text ) { SetIsReady( true ) ; }

	private:
		NS_IMPLEMENT_INLINE_REFLECTION( HintItemViewModel, ArkaenNoesis::MVVM::ViewModelBase,
										"LimesFractus.GUI.ViewModels.Controls.HintItemViewModel" ) {
			NsProp( "Glyph", &HintItemViewModel::GetGlyph,
							 &HintItemViewModel::SetGlyph ) ;
			NsProp( "Text", &HintItemViewModel::GetText,
							&HintItemViewModel::SetText ) ;
		}
	} ;
	ARKAEN_NOESIS_AUTO_COMPONENT( HintItemViewModel )
}
My "HintBarViewModel" can then just add them like Add( u8"\u2139", "Pre-Alpha Test Build" ) ; and that displays emojis for me ... I just wish Noto Color Emoji would work for me. Full color emojis were working for me in Unity, strangely enough. Don't know if that's a font issue or something else.

But I seem to have run into a more serious thing ... I discovered that ComboBox, Menu and basically anything that has some kind of popup/drop-down/fly-out component to it doesn't seem to work. I'm kind of at a loss to explain that ... there's no binding errors or warning/error messages of any kind and I can focus the control and use arrow keys and enter to change the selected item but I never get a Combobox drop menu on the screen ... apparently, not even an invisible one because clicking around that area just unfocuses and only keyboard can change the selection.

Any idea where things might be going wrong? Is there some kind of special rendering layer I forgot (didn't notice such a thing mentioned in documentation or samples)? Or does it have to do with input or something else entirely?

-------

EDIT ::

I figured this issue out, too, and I'll leave the answer here as a resource for the community in case anyone else has the same issue in their own integration. I goofily was passing deltaTime to IView::Update and it needs a continuous, global time to drive animations and state changes and stuff. Doing this means it interprets time as staying essentially frozen (whatever your frame time is). A really simple way to provide this is:
    void ArkaenNoesisHost::Update( double dtSeconds ) {
        static double globalTime = 0.0 ;
        globalTime += dtSeconds ;
        if( !m_view ) return ;
        m_view->Update( globalTime ) ;
    }
I read the documentation and somehow forgot whilst dealing with other things, but my memory was jogged when I considered time/animation, haha ...

Re: DirectX 12 custom engine questions

Posted: 20 Feb 2026, 21:40
by jsantos
Thanks for the feedback and for coming back with an update.

I initially thought this might be related to offscreen rendering and was going to suggest using RenderDoc to compare snapshots between your render and ours.

It’s great to see that you were able to identify the issue 🙂

Re: DirectX 12 custom engine questions

Posted: 03 Mar 2026, 04:34
by arkaen
Thanks for the feedback and for coming back with an update.

I initially thought this might be related to offscreen rendering and was going to suggest using RenderDoc to compare snapshots between your render and ours.

It’s great to see that you were able to identify the issue 🙂
No problem, and I'll be continuing this and R&D with Unity and Unreal since I'm going all-in on Noesis adoption. :-)

I took some time to handle some of the more "boring" and less glamorous parts of engine programming and wrote a nice json settings/configuration, environment variable and launch system which is why I've been quite for some days. It's kind of like Houdini's environment variables where you can just write "$ASSETS/Models/Thing.fbx" or "$GUI/Views/Something.xaml" and it gets resolved.

But a couple questions occurred to me ...

1) How exactly does the concept of "assemblies" work with the native SDK? What do you have to do to "register" an assembly and/or name it? I started thinking about this so that I can have scoped providers for XAML and other things at a per-assembly level.

2) What (if anything) needs to be done to integrate audio and play sounds through Noesis that are specified in the XAML? I still have to add the Interactions support so I haven't tested it the "usual" way yet:
<b:Interaction.Triggers>
	<b:EventTrigger EventName="MouseDown">
		<b:PlaySoundAction Source="{StaticResource UIClickAudioClip}" Volume="1.0" />
	</b:EventTrigger>
</b:Interaction.Triggers>
But once I support this will sound just play for me, or is there more to it? I don't see much about in the documentation and was curious how I'll be able to control things. I know of the "Noesis::GUI::PlayAudio" function, but was curious how this needs to be wired up to work as expected ...