[quote="DarkStarSword"]Have you ever wanted to view the contents of a constant buffer live while playing the game? I know I sure have... Well, now you can:
[/quote]
I'm speechless, I've been waiting for it sine I started my journey with 3DM :D
DarkStarSword said:Have you ever wanted to view the contents of a constant buffer live while playing the game? I know I sure have... Well, now you can:
I'm speechless, I've been waiting for it sine I started my journey with 3DM :D
[quote="Oomek"]I'm trying to draw 2 small debug resources ResourceDepthBuffer and ResourceLakePositionBuffer. Because ResourceLakePositionBuffer is using Draw = from_caller the area of the geometry gets updated, the rest of the resource contains stale information,so I'm using a custom shader to clear it. post run = CustomShaderClearRT does nothing. When I use run = CustomShaderClearRT the whole back buffer goes black. Do you know by any chance what am I doing wrong? I thought ResourceLakePositionBuffer = null will work, but it does nothing as well.
[code]
[ResourceDepthBuffer]
[ResourceLakePositionBuffer]
format = R8G8B8A8_UNORM
max_copies_per_frame=1
[ShaderOverride-SkyPS]
Hash = 5fb7805badf885b7
ResourceDepthBuffer = copy oD
[CustomShaderPostprocess]
vs = ShaderFixes\postProcess.vs.hlsl
ps = ShaderFixes\postProcess.ps.hlsl
blend = disable
x1=rt_width
y1=rt_height
ps-t104 = bb
ps-t105 = ResourceDepthBuffer
ps-t106 = ResourceLakePositionBuffer
o0 = bb
draw = 6, 0
[ResourceBackupo0]
[ResourceBackupo1]
[CustomShaderPositionBuffer]
blend = disable
ps = ShaderFixes\position.ps.hlsl
ResourceLakePositionBuffer = copy_desc o0
ResourceBackupo0 = ref o0
o0 = ResourceLakePositionBuffer
Draw = from_caller
post o0 = ResourceBackupo0
[ShaderOverride-665483756892af90-vs]
hash = 665483756892af90
run = CustomShaderPositionBuffer
[CustomShaderClearRT]
blend = disable
vs = ShaderFixes\clear_rt.vs.hlsl
ps = ShaderFixes\clear_rt.ps.hlsl
ResourceBackupo0 = ref o0
o0 = ResourceLakePositionBuffer
Draw = 6, 0
post o0 = ResourceBackupo0
[Present]
ResourceLakePositionBuffer = null
run = CustomShaderClearRT //post run = CustomShaderClearRT
run = CustomShaderPostprocess
[/code]
[/quote]
Oh the irony, I've been debugging that debug view for the last 3 days and I'm stuck :) Is there something wrong with me :) ?
Oomek said:I'm trying to draw 2 small debug resources ResourceDepthBuffer and ResourceLakePositionBuffer. Because ResourceLakePositionBuffer is using Draw = from_caller the area of the geometry gets updated, the rest of the resource contains stale information,so I'm using a custom shader to clear it. post run = CustomShaderClearRT does nothing. When I use run = CustomShaderClearRT the whole back buffer goes black. Do you know by any chance what am I doing wrong? I thought ResourceLakePositionBuffer = null will work, but it does nothing as well.
[ResourceDepthBuffer]
[ResourceLakePositionBuffer]
format = R8G8B8A8_UNORM
max_copies_per_frame=1
[ShaderOverride-SkyPS]
Hash = 5fb7805badf885b7
ResourceDepthBuffer = copy oD
The order in the [Present] section is wrong - setting ResourceLakePositionBuffer to null removes your reference to it so the next two custom shaders then won't be able to use it, and you are running the clear custom shader before the debug custom shader, so again it won't have anything to render.
Also, the "//post run = CustomShaderClearRT" comment is not the correct way to comment an ini file which would cause that whole line not to run (if it is running anyway that is technically a bug). Comments start with a semicolon and have to be on a line by themselves.
It should be:
[code]
[Present]
run = CustomShaderPostprocess
run = CustomShaderClearRT
ResourceLakePositionBuffer = null
[/code]
(At some point I need to add new keywords to clear render targets and UAVs using the API calls instead of having to use a custom shader - after reading one of NVIDIA's white papers I found out that the driver uses them to determine whether a resource needs to be propagated between frames/GPUs in AFR SLI).
The order in the [Present] section is wrong - setting ResourceLakePositionBuffer to null removes your reference to it so the next two custom shaders then won't be able to use it, and you are running the clear custom shader before the debug custom shader, so again it won't have anything to render.
Also, the "//post run = CustomShaderClearRT" comment is not the correct way to comment an ini file which would cause that whole line not to run (if it is running anyway that is technically a bug). Comments start with a semicolon and have to be on a line by themselves.
It should be:
[Present]
run = CustomShaderPostprocess
run = CustomShaderClearRT
ResourceLakePositionBuffer = null
(At some point I need to add new keywords to clear render targets and UAVs using the API calls instead of having to use a custom shader - after reading one of NVIDIA's white papers I found out that the driver uses them to determine whether a resource needs to be propagated between frames/GPUs in AFR SLI).
2x Geforce GTX 980 in SLI provided by NVIDIA, i7 6700K 4GHz CPU, Asus 27" VG278HE 144Hz 3D Monitor, BenQ W1070 3D Projector, 120" Elite Screens YardMaster 2, 32GB Corsair DDR4 3200MHz RAM, Samsung 850 EVO 500G SSD, 4x750GB HDD in RAID5, Gigabyte Z170X-Gaming 7 Motherboard, Corsair Obsidian 750D Airflow Edition Case, Corsair RM850i PSU, HTC Vive, Win 10 64bit
[quote="DarkStarSword"]The order in the [Present] section is wrong - setting ResourceLakePositionBuffer to null removes your reference to it so the next two custom shaders then won't be able to use it, and you are running the clear custom shader before the debug custom shader, so again it won't have anything to render.
Also, the "//post run = CustomShaderClearRT" comment is not the correct way to comment an ini file which would cause that whole line not to run (if it is running anyway that is technically a bug). Comments start with a semicolon and have to be on a line by themselves.
It should be:
[code]
[Present]
run = CustomShaderPostprocess
run = CustomShaderClearRT
ResourceLakePositionBuffer = null
[/code][/quote]
Unfortunately run = CustomShaderClearRT is making the whole screen black, I've already tried all the combinations, including your suggestion, so it must be something else.
// line was added on the forum, forgive me my faux pas :)
DarkStarSword said:The order in the [Present] section is wrong - setting ResourceLakePositionBuffer to null removes your reference to it so the next two custom shaders then won't be able to use it, and you are running the clear custom shader before the debug custom shader, so again it won't have anything to render.
Also, the "//post run = CustomShaderClearRT" comment is not the correct way to comment an ini file which would cause that whole line not to run (if it is running anyway that is technically a bug). Comments start with a semicolon and have to be on a line by themselves.
It should be:
[Present]
run = CustomShaderPostprocess
run = CustomShaderClearRT
ResourceLakePositionBuffer = null
Unfortunately run = CustomShaderClearRT is making the whole screen black, I've already tried all the combinations, including your suggestion, so it must be something else.
// line was added on the forum, forgive me my faux pas :)
That, was actually one of the orders I've tried first. What I posted was the illogical one which I tried when common sense started to fail me :) But why CustomShaderClearRT is painting over the backbuffer I have no clue. I have stated o0 = ResourceLakePositionBuffer, when I do not clear I can see it's beeing drawn on. CustomShaderPositionBuffer is working without issues.
That, was actually one of the orders I've tried first. What I posted was the illogical one which I tried when common sense started to fail me :) But why CustomShaderClearRT is painting over the backbuffer I have no clue. I have stated o0 = ResourceLakePositionBuffer, when I do not clear I can see it's beeing drawn on. CustomShaderPositionBuffer is working without issues.
I can't see anything else wrong there - it can be worthwhile checking the d3d11_log.txt for 'WARNING', 'error' and the like, and take a frame analysis dump with 'analyse_options=log' and search the resulting FrameAnalysis-.../log.txt file for "3DMigoto" to check that all the command list commands happened in the order you expect.
I can't see anything else wrong there - it can be worthwhile checking the d3d11_log.txt for 'WARNING', 'error' and the like, and take a frame analysis dump with 'analyse_options=log' and search the resulting FrameAnalysis-.../log.txt file for "3DMigoto" to check that all the command list commands happened in the order you expect.
2x Geforce GTX 980 in SLI provided by NVIDIA, i7 6700K 4GHz CPU, Asus 27" VG278HE 144Hz 3D Monitor, BenQ W1070 3D Projector, 120" Elite Screens YardMaster 2, 32GB Corsair DDR4 3200MHz RAM, Samsung 850 EVO 500G SSD, 4x750GB HDD in RAID5, Gigabyte Z170X-Gaming 7 Motherboard, Corsair Obsidian 750D Airflow Edition Case, Corsair RM850i PSU, HTC Vive, Win 10 64bit
Do you have any means to run it in game at the moment by any chance?
I could give you the shaders. If you say everything is ok in the ini then I do not know, maybe I did something wrong in the shader's code, which I doubt. clear_rt is a carbon copy of your code. postprocess and position shader are running fine, so what is wrong? Have I discovered a bug?
Do you have any means to run it in game at the moment by any chance?
I could give you the shaders. If you say everything is ok in the ini then I do not know, maybe I did something wrong in the shader's code, which I doubt. clear_rt is a carbon copy of your code. postprocess and position shader are running fine, so what is wrong? Have I discovered a bug?
By looking at the log I have a feeling the order is wrong, it should go like this:
1. ShaderOverride-665483756892af90-vs calls CustomShaderPositionBuffer which fills up ResourceLakePositionBuffer
2. CustomShaderPostprocess displays ResourceDepthBuffer and ResourceLakePositionBuffer in small windows
3. CustomShaderClearRT clears ResourceLakePositionBuffer [s](can also be called at the begining)[/s]
edit: seems fine as I didn't see the 3dmigoto entries in the middle of the log file
By looking at the log I have a feeling the order is wrong, it should go like this:
1. ShaderOverride-665483756892af90-vs calls CustomShaderPositionBuffer which fills up ResourceLakePositionBuffer
2. CustomShaderPostprocess displays ResourceDepthBuffer and ResourceLakePositionBuffer in small windows
3. CustomShaderClearRT clears ResourceLakePositionBuffer (can also be called at the begining)
edit: seems fine as I didn't see the 3dmigoto entries in the middle of the log file
This is how it supposed to look like (ignoring the stale data of the position buffer) when I do not clear the buffer. When I do the screen fills up with the color I set in the clear_rt.ps.hlsl
[img]https://s29.postimg.org/x1smbqn6f/dirt3_game_2017_01_03_02_09_45_284.png[/img]
Don't mind the lake, I just filled it up with solid color temporarily.
This is how it supposed to look like (ignoring the stale data of the position buffer) when I do not clear the buffer. When I do the screen fills up with the color I set in the clear_rt.ps.hlsl
Don't mind the lake, I just filled it up with solid color temporarily.
I think I know what it is - you have ResourceLakePositionBuffer bound as both an input and output simultaneously, so DirectX will have ignored your attempt to bind it to o0, leaving the back buffer bound instead.
Add these lines to [CustomShaderPostprocess]:
post ps-t105 = null
post ps-t106 = null
I think I know what it is - you have ResourceLakePositionBuffer bound as both an input and output simultaneously, so DirectX will have ignored your attempt to bind it to o0, leaving the back buffer bound instead.
Add these lines to [CustomShaderPostprocess]:
post ps-t105 = null
post ps-t106 = null
2x Geforce GTX 980 in SLI provided by NVIDIA, i7 6700K 4GHz CPU, Asus 27" VG278HE 144Hz 3D Monitor, BenQ W1070 3D Projector, 120" Elite Screens YardMaster 2, 32GB Corsair DDR4 3200MHz RAM, Samsung 850 EVO 500G SSD, 4x750GB HDD in RAID5, Gigabyte Z170X-Gaming 7 Motherboard, Corsair Obsidian 750D Airflow Edition Case, Corsair RM850i PSU, HTC Vive, Win 10 64bit
[quote="DarkStarSword"]I think I know what it is - you have ResourceLakePositionBuffer bound as both an input and output simultaneously, so DirectX will have ignored your attempt to bind it to o0, leaving the back buffer bound instead.
Add these lines to [CustomShaderPostprocess]:
post ps-t105 = null
post ps-t106 = null[/quote]
Still the same I'm afraid :/
What about the Back Buffer? I also read and write to it, is that legal?
DarkStarSword said:I think I know what it is - you have ResourceLakePositionBuffer bound as both an input and output simultaneously, so DirectX will have ignored your attempt to bind it to o0, leaving the back buffer bound instead.
Add these lines to [CustomShaderPostprocess]:
post ps-t105 = null
post ps-t106 = null
Still the same I'm afraid :/
What about the Back Buffer? I also read and write to it, is that legal?
I'm losing my mind here. This does not make any sense... 4 days passed and I did not even start implementing ss reflections. I can start without debug view, but it will gonna be a guess work.
I'm losing my mind here. This does not make any sense... 4 days passed and I did not even start implementing ss reflections. I can start without debug view, but it will gonna be a guess work.
I'm speechless, I've been waiting for it sine I started my journey with 3DM :D
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
Oh the irony, I've been debugging that debug view for the last 3 days and I'm stuck :) Is there something wrong with me :) ?
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
Also, the "//post run = CustomShaderClearRT" comment is not the correct way to comment an ini file which would cause that whole line not to run (if it is running anyway that is technically a bug). Comments start with a semicolon and have to be on a line by themselves.
It should be:
(At some point I need to add new keywords to clear render targets and UAVs using the API calls instead of having to use a custom shader - after reading one of NVIDIA's white papers I found out that the driver uses them to determine whether a resource needs to be propagated between frames/GPUs in AFR SLI).
2x Geforce GTX 980 in SLI provided by NVIDIA, i7 6700K 4GHz CPU, Asus 27" VG278HE 144Hz 3D Monitor, BenQ W1070 3D Projector, 120" Elite Screens YardMaster 2, 32GB Corsair DDR4 3200MHz RAM, Samsung 850 EVO 500G SSD, 4x750GB HDD in RAID5, Gigabyte Z170X-Gaming 7 Motherboard, Corsair Obsidian 750D Airflow Edition Case, Corsair RM850i PSU, HTC Vive, Win 10 64bit
Alienware M17x R4 w/ built in 3D, Intel i7 3740QM, GTX 680m 2GB, 16GB DDR3 1600MHz RAM, Win7 64bit, 1TB SSD, 1TB HDD, 750GB HDD
Pre-release 3D fixes, shadertool.py and other goodies: http://github.com/DarkStarSword/3d-fixes
Support me on Patreon: https://www.patreon.com/DarkStarSword or PayPal: https://www.paypal.me/DarkStarSword
Unfortunately run = CustomShaderClearRT is making the whole screen black, I've already tried all the combinations, including your suggestion, so it must be something else.
// line was added on the forum, forgive me my faux pas :)
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
2x Geforce GTX 980 in SLI provided by NVIDIA, i7 6700K 4GHz CPU, Asus 27" VG278HE 144Hz 3D Monitor, BenQ W1070 3D Projector, 120" Elite Screens YardMaster 2, 32GB Corsair DDR4 3200MHz RAM, Samsung 850 EVO 500G SSD, 4x750GB HDD in RAID5, Gigabyte Z170X-Gaming 7 Motherboard, Corsair Obsidian 750D Airflow Edition Case, Corsair RM850i PSU, HTC Vive, Win 10 64bit
Alienware M17x R4 w/ built in 3D, Intel i7 3740QM, GTX 680m 2GB, 16GB DDR3 1600MHz RAM, Win7 64bit, 1TB SSD, 1TB HDD, 750GB HDD
Pre-release 3D fixes, shadertool.py and other goodies: http://github.com/DarkStarSword/3d-fixes
Support me on Patreon: https://www.patreon.com/DarkStarSword or PayPal: https://www.paypal.me/DarkStarSword
frame analysis log is a bit to big for paste bin, so I'll skip some data
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
I could give you the shaders. If you say everything is ok in the ini then I do not know, maybe I did something wrong in the shader's code, which I doubt. clear_rt is a carbon copy of your code. postprocess and position shader are running fine, so what is wrong? Have I discovered a bug?
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
1. ShaderOverride-665483756892af90-vs calls CustomShaderPositionBuffer which fills up ResourceLakePositionBuffer
2. CustomShaderPostprocess displays ResourceDepthBuffer and ResourceLakePositionBuffer in small windows
3. CustomShaderClearRT clears ResourceLakePositionBuffer
(can also be called at the begining)edit: seems fine as I didn't see the 3dmigoto entries in the middle of the log file
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
Don't mind the lake, I just filled it up with solid color temporarily.
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
Add these lines to [CustomShaderPostprocess]:
post ps-t105 = null
post ps-t106 = null
2x Geforce GTX 980 in SLI provided by NVIDIA, i7 6700K 4GHz CPU, Asus 27" VG278HE 144Hz 3D Monitor, BenQ W1070 3D Projector, 120" Elite Screens YardMaster 2, 32GB Corsair DDR4 3200MHz RAM, Samsung 850 EVO 500G SSD, 4x750GB HDD in RAID5, Gigabyte Z170X-Gaming 7 Motherboard, Corsair Obsidian 750D Airflow Edition Case, Corsair RM850i PSU, HTC Vive, Win 10 64bit
Alienware M17x R4 w/ built in 3D, Intel i7 3740QM, GTX 680m 2GB, 16GB DDR3 1600MHz RAM, Win7 64bit, 1TB SSD, 1TB HDD, 750GB HDD
Pre-release 3D fixes, shadertool.py and other goodies: http://github.com/DarkStarSword/3d-fixes
Support me on Patreon: https://www.patreon.com/DarkStarSword or PayPal: https://www.paypal.me/DarkStarSword
Still the same I'm afraid :/
What about the Back Buffer? I also read and write to it, is that legal?
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64
EVGA GeForce GTX 980 SC
Core i5 2500K
MSI Z77A-G45
8GB DDR3
Windows 10 x64