@mjp@mastodon.gamedev.place avatar

mjp

@mjp@mastodon.gamedev.place

Lead Rendering Programmer at Sony Santa Monica Studio. Previously Engine Lead at Ready At Dawn Studios. Side-job as chief graphics meme officer. He/him. Check out my blog: https://therealmjp.github.io/

This profile is from a federated server and may be incomplete. Browse more on the original instance.

longbool, to random
@longbool@mastodon.gamedev.place avatar

R9B9G9E5 support for render targets and UAVs
https://devblogs.microsoft.com/directx/agility-sdk-1-614-0/

Pour one out for R11G11B10

mjp,
@mjp@mastodon.gamedev.place avatar

@aras @longbool Unfortunately it's not clear at all which hardware actually supports it at the moment. But I did at least confirm that it works on my RX 7900 XT, so that's something!

mjp, to random
@mjp@mastodon.gamedev.place avatar

After reading through the cool ZH3 paper (https://torust.me/ZH3.pdf), I added the ZH3 hallucination method for calculating irradiance to both BakingLab and Probulator

https://github.com/TheRealMJP/BakingLab/commit/0d6f4ceaed699fc32e94b9ae1919bedf7ae4e498

https://github.com/kayru/Probulator/commit/4a97a2b021eb2ca7ef696f4ddf36ba9a9432cbb6

aras, to random
@aras@mastodon.gamedev.place avatar

Was a good morning.

image/jpeg

mjp,
@mjp@mastodon.gamedev.place avatar

@aras my dog update: still sitting weirdly

mjp, to random
@mjp@mastodon.gamedev.place avatar

If an artist or game director ever tells you that you need to add an "eclipse mode", it's actually pretty easy to do just by modifying your shadow map PCF kernel! Just set the weights to match the shape of an occluded disk.

solidangle, to random
@solidangle@mastodon.gamedev.place avatar

The database feature I really want in my game dev pipeline is queries, not transactions.

"Fetch me all actors in the game that use this combination of properties and are affected by lights with this type of shadow filter"

"Tell me which post process volumes enable depth of field in the game"

mjp,
@mjp@mastodon.gamedev.place avatar

@solidangle I think WoW and other MMOs use actual real databases for everything which would presumably allow for queries like that. At my previous job there was a system that ran nightly to crawl through all of the content and build a queryable database which was neat. It was mostly used to figure out where assets were referenced though.

mjp,
@mjp@mastodon.gamedev.place avatar

@demofox @mjp @solidangle a good friend of mine used to be a designer at SOE and he told me he would fire up MS Access to manually enter data

mjp,
@mjp@mastodon.gamedev.place avatar

@sascha @solidangle databases are used in some places but it’s a tradeoff. Text assets are great in some ways because they’re readable, (somewhat) mergable, and can be searched or even modified without special tools. For having lots of people work in source control it’s also generally better to have lots of smaller individual files that can be modified and checked in independently. It’s also good for content processing pipelines that want to naturally parallelize on multiple input files.

mjp,
@mjp@mastodon.gamedev.place avatar

@demofox @solidangle @msinilo @mjp at the previous job all asset dependencies were static for the zone (streamable chunk of the world), with a statically-determined memory footprint. Anything spawned had to have a pre-allocated pool. Very restrictive, obviously! But good for tightening up memory for shipping. 😅

mjp,
@mjp@mastodon.gamedev.place avatar

@sascha @mjp @solidangle yeah I confess I’ve never worked with or explored such a setup…in my experience the runtime data structures were optimized and packed mostly as plain arrays of data with various mechanisms and concessions for being able to background stream in chunks of the world as you progress. Arrays of various component types are great for blasting through hundreds or thousands of things! But for truly global data a true DB might make sense as a shared resource.

mjp,
@mjp@mastodon.gamedev.place avatar

@nicebyte @mjp @sascha @solidangle I’m honestly not sure I have a good grasp of the tradeoffs on that scenario, like I said in the other thread the engine I spent the most time with used optimized and packed arrays for most things for minimal memory footprint and fast iteration. But there was definitely a lineage in that engine coming from single-player games running on consoles with very limited memory. 🙂

mjp,
@mjp@mastodon.gamedev.place avatar

@demofox @mjp @solidangle @msinilo I liked it too! Designers were understandably less enthusiastic. 😁

demofox, to random
@demofox@mastodon.gamedev.place avatar

PSA:
So the thing about employee stock purchase plans is it's a way for a company to pay you, but have you put some money back into the company as if they didn't (And you get a discount to sweeten the deal)
RSUs are similar - they are taxed like a cash bonus that you happened to buy company stock with.
These things can be beneficial, but it's good to know the score!
If you want the stock, cool. If not, sell both rsus and espp as you get them. Espp=Discounted money. Rsu=cash bonus.
FYI!

mjp,
@mjp@mastodon.gamedev.place avatar

@demofox personally I say always sell the RSUs and take the $$$. If something happens at the company you could find yourself without a job, and better to have money elsewhere than in a bunch of now-worthless stock.

mjp, to random
@mjp@mastodon.gamedev.place avatar

This is a great article that explains HLSL cbuffer packing rules, and also includes a very cool layout visualizer: https://maraneshi.github.io/HLSL-ConstantBufferLayoutVisualizer/

benoitvimont, to random French
@benoitvimont@mastodon.gamedev.place avatar

Finally, I added HLSL debug print/assert functionality to my pet engine.

Ended up not using the same HLSL template string trick from @aras because I wanted it to work even with -Od for shader debugging but still it should be a useful feature 🙂

mjp, (edited )
@mjp@mastodon.gamedev.place avatar

@aras @benoitvimont I’ve been telling everyone that Aras came up with that horrible template thing so that I don’t get blamed for it 😆

mjp, to random
@mjp@mastodon.gamedev.place avatar

I can confirm that the new RAD Debugger builds almost instantly, and works on my code:

mjp,
@mjp@mastodon.gamedev.place avatar

@castano there’s a pre-built binary on the releases page, but I built it myself because it was so easy (just run a batch file in a VS command prompt)

mjp,
@mjp@mastodon.gamedev.place avatar
mjp,
@mjp@mastodon.gamedev.place avatar

@castano @aras Indeed Windows-only at the moment. Their readme does mention "In the future we'll expand to also support native Linux debugging and DWARF debug info."

mjp, to random
@mjp@mastodon.gamedev.place avatar

If you want to learn how to implement a simple shader printf in HLSL 2021 and D3D12, then I've got a new blog post for you: https://therealmjp.github.io/posts/hlsl-printf/

froyok, to random
@froyok@mastodon.gamedev.place avatar

I wonder if anybody tried to use FXAA before doing display mapping BUT by still applying and reverting a curve ? 🤔

Aka:
1 - Switch from HDR to SDR
2 - Apply FXAA
3 - Switch back from SDR to HDR
4 - Apply regular post-process stuff

mjp,
@mjp@mastodon.gamedev.place avatar
Humus, (edited ) to random
@Humus@mastodon.gamedev.place avatar

Friendly reminder to never read from write-combined memory (e.g. upload buffers) because that absolutely kills performance.

Note that you can run into this even if your C++ code is just a bunch of straight writes, if the compiler generates the wrong code. I ran into this with the D3D12_RAYTRACING_INSTANCE_DESC struct, because it contains bitfields, and the compiler generated XOR & AND to memory destination. So that's a read-modify-write operation. Probably relatively harmless on regular memory.

mjp,
@mjp@mastodon.gamedev.place avatar

@Humus it gets even worse if the buffer lives in VRAM and is read through BAR…uncached reads over PCIe are just brutally slow.

castano, to random
@castano@mastodon.gamedev.place avatar

I wish I could visualize the register use of a shader program for every line statement. If a statement is used in multiple code paths, I would want to see the maximum register use, which is what matters. Is there any tool out there that accomplishes this?

mjp,
@mjp@mastodon.gamedev.place avatar

@castano Radeon GPU Analzer is the only public tool I know of that can show you register pressure for each instruction: https://radeon-gpu-analyzer-rga.readthedocs.io/en/latest/help_manual.html#id19

mjp, to random
@mjp@mastodon.gamedev.place avatar

My very brief summary of Apple's new "dynamic caching" as described in this video: https://developer.apple.com/videos/play/tech-talks/111375

There's a shared pool of on-chip memory on the shader core that can be dynamically split up to serve as register file, tile cache, shared memory, general buffer L1, or stack. Since it's dynamic even within the lifetime of a thread/wave, the registers can be allocated dynamically as the program needs them rather than needing registers to be statically-allocated up-front.

mjp,
@mjp@mastodon.gamedev.place avatar

What this means is that you only allocate registers for worst-case paths if they actually get executed. And even if those paths do run, regs can get "tetris'ed" together with the other executing waves which may be executing a different part of the program (or a different program), which allows for higher overall occupancy. If that on-chip memory runs out it spills to L2, but there's some kind of hardware magic to monitor for that and adjust occupancy to try to balance spilling vs. occupancy.

mjp,
@mjp@mastodon.gamedev.place avatar

It's very exciting to see such a radically new design for GPUs. In two of my blog posts I wrote about how the need for static register allocation makes it difficult to optimize shader for performance without an explosion of permutations/variants.

https://therealmjp.github.io/posts/shader-permutations-part1/

https://therealmjp.github.io/posts/shader-permutations-part2/

  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • magazineikmin
  • Youngstown
  • khanakhh
  • ngwrru68w68
  • slotface
  • ethstaker
  • mdbf
  • everett
  • kavyap
  • DreamBathrooms
  • thenastyranch
  • cisconetworking
  • rosin
  • JUstTest
  • Durango
  • GTA5RPClips
  • anitta
  • tester
  • tacticalgear
  • InstantRegret
  • normalnudes
  • osvaldo12
  • cubers
  • provamag3
  • modclub
  • Leos
  • lostlight
  • All magazines