Psprites scaled different between hardware/software

Is there something that doesn't work right in the latest GZDoom? Post about it here.

Moderator: GZDoom Developers

Forum rules
Please construct and post a simple demo whenever possible for all bug reports. Please provide links to everything.

If you can include a wad demonstrating the problem, please do so. Bug reports that include fully-constructed demos have a much better chance of being investigated in a timely manner than those that don't.

Please make a new topic for every bug. Don't combine multiple bugs into a single topic. Thanks!

Psprites scaled different between hardware/software

Postby NeoTerraNova » Tue Nov 23, 2021 6:16 pm

Greetings, everyone. Once again, I humbly ask for the help of anyone and everyone that can assist me. Again, as always, I thank each of you that stops by to help. You all really have no idea how thankful and grateful I am for all the help I get on here.

I think my problem might be simple, but I don't know. I have a number of weapons that have an Aim-Down-Sights function. In relation to my most-previous post regarding flashlights, I decided to set about trying to run in Hardware mode, if I can. The problem is, the "center" of my screen seems to have "dropped" somewhat.

To put it another way - I have the graphics for the Aim-Down-Sights options configured to be precisely at the center of the screen, so the Player can put their sights on the target and know the bullet is going to hit right there. This was set up for Software mode, as it's the only mode I've used for years, given my Potato Spud of a computer. When I switched over to Hardware Mode to see if I can manage it (I haven't in the past, but, you know, things can change), the point-of-impact dropped significantly.

Given that different users will use different configurations, is there some way to be absolutely certain that the position on the screen where I want to imply that the fired bullet will hit, will be the same, no matter who's computer it's on? Barring that, is there some way for the end user to manipulate the menu options to move the point-of-impact to where it "should" be in Software mode?

I apologize for posting here - I wans't sure if this was a Scripting issue, or something to do with the game's settings.
Last edited by Caligari87 on Wed Nov 24, 2021 10:05 am, edited 2 times in total.
Reason: Title edited for topic move to Bugs forum
User avatar
NeoTerraNova
 
Joined: 14 Mar 2017
Location: Western North Southlandia (East Side)

Re: Wandering Zero (center of screen)

Postby determin1st » Tue Nov 23, 2021 8:07 pm

i think center is 44 units, and zero in A_FireCustomMissile is at 41 units, so to center projectile offset should be +3

anyway, it will go to the center point from any offset (when angle/pitch=0)..

also check the puff sprite, if it's not centered, may showup screwed
User avatar
determin1st
 
Joined: 06 Oct 2021

Re: Wandering Zero (center of screen)

Postby NeoTerraNova » Tue Nov 23, 2021 8:56 pm

Hey, thanks for the reply, but I think you might be missing what I'm trying to explain. I apologize, I should have been a bit more plain.

When in Software Mode, my Sights and the Point-of-Impact like up like this:

__{RS}_X_{RS}__

Where "{RS}" is the rear sight, and X is both the front sight and the point-of-impact of each shot.

Now, in Hardware Mode, it's coming out like this:

__{RS}_[FS]_{RS}__

..........X............

Where "[FS]" is the Front Sight, and "X" is the point-of-impact again. In Hardware Mode, for reasons I don't understand, the point-of-impact is significantly lower than where it is in Software Mode. As a result, the graphics I have for Aim-Down-Sights are horribly mis-aligned in Hardware Mode, where in Software Mode, they line up perfectly.

Is this a better explanation? I apologize if I wasn't clear, before.
User avatar
NeoTerraNova
 
Joined: 14 Mar 2017
Location: Western North Southlandia (East Side)

Re: Wandering Zero (center of screen)

Postby Caligari87 » Tue Nov 23, 2021 11:30 pm

I'd wager this isn't the "center of your screen" being misaligned, but rather your sight graphics being placed differently on the screen between the hardware and software renderers for some reason. For the record I've not heard of this and it might be an engine bug, but I'm not 100% sure of that.

Unfortunately this isn't possible to troubleshoot based solely on your description. Can you strip down your mod and make a minimal example that shows the problem happening, then upload here? Also please make sure to post your GZDoom version, and your system specs (GPU, CPU, operating system, graphics driver version, etc).

8-)
User avatar
Caligari87
I'm just here for the community
User Accounts Assistant
 
Joined: 26 Feb 2004
Location: Salt Lake City, Utah, USA
Discord: Caligari87#3089
Github ID: caligari87
Operating System: Debian-like Linux (Debian, Ubuntu, Mint, etc) 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Wandering Zero (center of screen)

Postby NeoTerraNova » Wed Nov 24, 2021 12:37 am

I'd wager this isn't the "center of your screen" being misaligned, but rather your sight graphics being placed differently on the screen between the hardware and software renderers for some reason.


This is exactly what I was thinking.

For the record I've not heard of this and it might be an engine bug, but I'm not 100% sure of that.


Oh, dear.. I hope not.

Unfortunately this isn't possible to troubleshoot based solely on your description. Can you strip down your mod and make a minimal example that shows the problem happening, then upload here? Also please make sure to post your GZDoom version, and your system specs (GPU, CPU, operating system, graphics driver version, etc).


The potato is:
Acer Aspire
Intel 2020M Dual 2.4GHz
Windows 7
Standard Intel HD Graphics card/on-board, Driver version 8.15.10.2752 from 2012.

As for which Source Ports, I'm using GZDoom 4.5.0 and LZDoom 1.88, and the problem is with both of them.

I was picking through GZDoom 4.5.0 and hot-swapping the rendering modes, and I actually saw my graphic increase in size on the screen, between the two modes. In Hardware mode, it appearing larger on the screen, and in Software mode, smaller. This right here is the source of the issue - somehow, between the two rendering modes, my graphics are being magnified (or, to the eye of the person playing, they appear larger). And the magnification is enough to throw off point-of-aim from point-of-impact. Any idea what might cause THIS?

Also, it would be VERY hard for me to strip down my Mod to display this problem - frankly, every graphic that's involved with this problem, is my own hard work, and I don't want any of it displayed to the world until I'm as done as I can get. I've seen too many times what happens when a broken Alpha or something gets "released" before the creator is ready. If I have to, I'll make a separate set of graphics that has the same demonstrable problem and make a special WAD file. However, I'd really prefer to avoid that.

EDIT: I should also note that switching Aspect Ratio also causes this problem - the Sprite for my weapons is stretched somehow, and it also throws off Point-of-Aim from Point-of-Impact. Just found this out.
User avatar
NeoTerraNova
 
Joined: 14 Mar 2017
Location: Western North Southlandia (East Side)

Re: Wandering Zero (center of screen)

Postby Caligari87 » Wed Nov 24, 2021 10:03 am

The aspect ratio scaling part kinda makes sense? Some modes simply have different pixel stretch ratios.

The scaling difference between hardware and software rendering does sound like a bug though (unless someone smarter and more knowledgeable than me can chime in). I've moved this topic to the Bug Reports forum for better visibility and changed your thread title accordingly (if it's not a bug we'll close it or move the topic back to an editing help forum).

I understand not wanting to make your mod public, but we do need something to troubleshoot. Please be prepared to private message a developer with your mod. Note that the more complex a mod is, the harder it is for devs to troubleshoot, so please try to find a way to strip it down to an easy example like a single weapon if possible, and clearly describe how to reproduce the issue.

8-)
User avatar
Caligari87
I'm just here for the community
User Accounts Assistant
 
Joined: 26 Feb 2004
Location: Salt Lake City, Utah, USA
Discord: Caligari87#3089
Github ID: caligari87
Operating System: Debian-like Linux (Debian, Ubuntu, Mint, etc) 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Psprites scaled different between hardware/software

Postby NeoTerraNova » Wed Nov 24, 2021 11:18 am

Alright, I think I can strip it all the way down to one weapon that I no longer use, that still exhibits the problem. Give me a couple hours to see if I can reproduce what's going on, with this, and I'll post everything here.

EDIT: I have something all ready to test.
User avatar
NeoTerraNova
 
Joined: 14 Mar 2017
Location: Western North Southlandia (East Side)


Return to Bugs

Who is online

Users browsing this forum: No registered users and 0 guests