Search found 2362 matches

by dpJudas
Mon Aug 04, 2025 5:59 pm
Forum: Feature Suggestions [GZDoom]
Topic: Expose canvas texture creation to ZScript
Replies: 21
Views: 776

Re: Expose canvas texture creation to ZScript

shrug Doesn't really matter if it's only if the keep alive function is called, or if it also keeps its contents as long as it's being rendered, the point was that it's not all that hard to come up with a system that allows the engine to automatically manage the lifetime of the hardware resources. I ...
by dpJudas
Mon Aug 04, 2025 4:28 pm
Forum: Feature Suggestions [GZDoom]
Topic: Expose canvas texture creation to ZScript
Replies: 21
Views: 776

Re: Expose canvas texture creation to ZScript

I never said the contents would be kept. Like I said, you'd have a "keep alive" function on the ZScript side. If the modder doesn't call it every frame, it's their problem if the texture loses its contents. That will work but then why not always just drop the texture if keep alive isn't called? You ...
by dpJudas
Mon Aug 04, 2025 3:07 pm
Forum: Feature Suggestions [GZDoom]
Topic: Expose canvas texture creation to ZScript
Replies: 21
Views: 776

Re: Expose canvas texture creation to ZScript

If the engine destroys a texture due to not having seen it for a while there's no bringing it back. It could recreate it next time zscript/game uses it, but its contents will be lost. Effectively this will just be the 1024 limit anyway, except now you will notice by the textures turning black if ...
by dpJudas
Mon Aug 04, 2025 11:45 am
Forum: Feature Suggestions [GZDoom]
Topic: Expose canvas texture creation to ZScript
Replies: 21
Views: 776

Re: Expose canvas texture creation to ZScript

I meant the total GPU memory usage. 64 2048x2048 (16MB each) textures, 256 1024x1024 (4MB each), 1024 512x512 (1MB each), 1024 256x256 (256KB each; texture count limit kicks in instead). Keep in mind that Nvidia and AMD still sell GPU's with 8 GB of memory. The frame buffers and other engine buffers ...
by dpJudas
Mon Aug 04, 2025 6:20 am
Forum: Feature Suggestions [GZDoom]
Topic: Expose canvas texture creation to ZScript
Replies: 21
Views: 776

Re: Expose canvas texture creation to ZScript

I don't think its a good idea to let the user control stuff like this. Newer versions of GZDoom could increase the limit, but of course, those clinging to decade old graphics cards will then run into trouble. If you have it as a CVAR you just forward the nightmare to the mod: they will not know what ...
by dpJudas
Mon Aug 04, 2025 3:37 am
Forum: Feature Suggestions [GZDoom]
Topic: Expose canvas texture creation to ZScript
Replies: 21
Views: 776

Re: Expose canvas texture creation to ZScript

Just to clarify: the limit could be that you can allocate a maximum of 1024 textures and they can totally only use 1 gigabyte of memory. Exceed any of those and Canvas.Create will begin to return null or throw an exception.
by dpJudas
Mon Aug 04, 2025 3:30 am
Forum: Feature Suggestions [GZDoom]
Topic: Expose canvas texture creation to ZScript
Replies: 21
Views: 776

Re: Expose canvas texture creation to ZScript

When the game dies with "device lost", "could not allocate descriptor set" or "could not allocate image" nobody blames the mod - they blame the engine. The difference between Canvas.Create and what we have now is that today everyone (engine and mod) knows exactly how many textures they are going to ...
by dpJudas
Sun Aug 03, 2025 5:50 pm
Forum: Feature Suggestions [GZDoom]
Topic: Expose canvas texture creation to ZScript
Replies: 21
Views: 776

Re: Expose canvas texture creation to ZScript

It isn't about making it impossible to mess things up. It is about avoiding solutions that are error prone and inevitably leading to people blaming the engine when they don't know why things blow up. I can think of a way to do it with the function AFADoomer suggested, but I'm not sure you're going ...
by dpJudas
Thu Jul 24, 2025 1:03 pm
Forum: Assets (and other stuff)
Topic: How to stop hardware renderer cutting of bottom of sprites
Replies: 7
Views: 179

Re: How to stop hardware renderer cutting of bottom of sprites

The modern GPU does not give the programmer complete control over how an image is rendered. The acceleration works by forcing certain constraints on the program and then accelerating the hell out of that specific method. Simply put, the GPU can only draw triangles. Either not clipped at all, or ...
by dpJudas
Sat May 31, 2025 8:39 pm
Forum: Technical Issues
Topic: Unable to launch ray tracing Doom.
Replies: 4
Views: 974

Re: Unable to launch ray tracing Doom.

If GZDoom RTX Mod works really well then what do you need GZDoom for? If its to implement missing features then I think its better to ask the GZDoom RTX developers to do that.
by dpJudas
Fri May 30, 2025 4:45 am
Forum: Creation, Conversion, and Editing
Topic: Ultimate Doom Builder
Replies: 1045
Views: 412972

Re: Ultimate Doom Builder

The key question here is whether "new Bitmap(loadbitmap)" is thread safe or not, since it might be both the UI thread and the background loader thread could be calling it. Not even sure if using Properties.Resources.UnknownImage directly instead would be safer. The way Microsoft implemented their ...
by dpJudas
Fri May 30, 2025 3:18 am
Forum: Creation, Conversion, and Editing
Topic: Ultimate Doom Builder
Replies: 1045
Views: 412972

Re: Ultimate Doom Builder

It is probably due to a race condition. Many years ago I tried to fix the threaded loading of images in UDB which was done completely wrong. The code basically didn't lock access to shared variables and it created win32 objects (such as System.Drawing.Bitmap) on worker threads while the win32 GDI ...
by dpJudas
Sat May 10, 2025 5:06 pm
Forum: Feature Suggestions [GZDoom]
Topic: Expose canvas texture creation to ZScript
Replies: 21
Views: 776

Re: Expose canvas texture creation to ZScript

It was a deliberate design decision to not give a function like that. The canvas texture is allocated on the GPU and for that reason need strict resource control. Allowing zscript to create arbitrary textures with unknown lifetimes will create tons of problems for the engine. On top of that ZScript ...
by dpJudas
Fri Mar 07, 2025 7:51 am
Forum: General
Topic: Donate to this foum/development?
Replies: 4
Views: 553

Re: Donate to this foum/development?

For me it is the same: it only makes sense if it would be enough to make a living. As long as I must have a normal job I'd rather have the freedom to do whatever I want in my spare time with no strings attached.

Go to advanced search