Mixing issue, FXAA, Lighting question etc..
by Michael Tornberg · in Torque 3D Professional · 11/18/2011 (4:33 pm) · 23 replies
1. FIXED: It seems VSync is ignored.
Which is very weird considering I set the driver to "Force vsync". .. I'll look into it more closely but I wanted to bring it up. I don't think this is related to T3D at all really. Could be drivers related.
UPDATE:
This was drivers related. Updating to the very latest beta driver from nVidia fixed the issue.
2. When moving it seems the steps between frames are a fraction lagged. Causing the environment to move in a very very tiny rubber band fashion. Possibly related to the (1) issue. Most visible in windowed mode.
UPDATE 1:
After updating the drivers, the issue became even smaller. But motion is still a bit "stepped" in lack of a better word. The motion doesn't look fluid, it looks more like motion-by-integer. It kind of steps, one pixel at a time. I know it doesn't, but it is how it feels. Like something is a bit off.
UPDATE 2:
Turning off shadows fixed the "stepping" issue. When shadowing is off, the fluidity is incredible. I'll look into baking shadows as much as possible in the scene. Shadows seems to be very expensive in T3D.
3. Why does the light animation on the police cars stop when turning the back against them?
4. I can't seem to find how to set FXAA, MLAA or anything of the kind?
Update:
I found how to set it in the source. However, I still think this should go to into menu of some kind (perhaps the editor?) Along with other cool stuff I found, such as Chromatic abbreviation.
5. When zooming in, the crosshair is gone.
6. While zoomed it and firing at the sentry gun. The game crashed when I got hit and I hit the sentry at the same time.
7. Mixing of lights vs. alpha items seems to be off. First, here is an illustration of what I mean:

Here you can see that the light get cut off on the shadow. The one that is included with the car model.
You can also see that the light is not mixed the correct way on the car. The lights seems to be suppressed, rather than adding values to the resulting image.
Here is another example. The one in green is photoshopped to illustrate (kind of) what I expected to happen:

As you can also see, the red section shows that other added objects doesn't mix properly. They totally dominate their environment.
Also, the light shadow volumes doesn't properly trace model edges. As can be seen in the image above, the lights seems to have an issue when they are close to meshes. The edge tracing for the shadow volume seems to be incorrect. You can see how the light shines through the mesh, and a distance away begin to trace the shadow.
Maybe there is a setting to control this?
Here is another example to make it more clear. Here you can clearly see that the objects I am talking about totally dominate the scene. Here I added rain, and made the droplets huge in size. Because I wanted to test if they indeed ended up 'behind' the darker objects. This image also includes a comparison with 1.1. I loaded the scene into version 1.1 and the light behaves as expected there. Obviously the dark objects have been updated for 1.2 and thus don't load in 1.1. However, the light is not mixed in a faint fashion in 1.1.

8. The convex hull (hitbox) is catching the effects of the explosions etc..

9. Setting texture quality to low, causes the flares to disappear.
10. Shadows are clipped
11. Shooting at the ejected bullet casing in flight causes damage to the player.
Making this happen is very hard, since you have to actually hit the casing. But I found it easiest when shooting
at the ground moving backwards and rotating to the right. It is also possible that it's not the bullet casing at all, but rather that I actually manage to shoot myself while moving around. Please note that I am talking about the machine gun, not the grenade launcher etc..
Video sample:
Here is a video of the issues 7,8,10 and also other shadow issues
(Note: The video says 'out' but that is just the name of the video :), just click and it will play.)
Which is very weird considering I set the driver to "Force vsync". .. I'll look into it more closely but I wanted to bring it up. I don't think this is related to T3D at all really. Could be drivers related.
UPDATE:
This was drivers related. Updating to the very latest beta driver from nVidia fixed the issue.
2. When moving it seems the steps between frames are a fraction lagged. Causing the environment to move in a very very tiny rubber band fashion. Possibly related to the (1) issue. Most visible in windowed mode.
UPDATE 1:
After updating the drivers, the issue became even smaller. But motion is still a bit "stepped" in lack of a better word. The motion doesn't look fluid, it looks more like motion-by-integer. It kind of steps, one pixel at a time. I know it doesn't, but it is how it feels. Like something is a bit off.
UPDATE 2:
Turning off shadows fixed the "stepping" issue. When shadowing is off, the fluidity is incredible. I'll look into baking shadows as much as possible in the scene. Shadows seems to be very expensive in T3D.
3. Why does the light animation on the police cars stop when turning the back against them?
4. I can't seem to find how to set FXAA, MLAA or anything of the kind?
Update:
I found how to set it in the source. However, I still think this should go to into menu of some kind (perhaps the editor?) Along with other cool stuff I found, such as Chromatic abbreviation.
5. When zooming in, the crosshair is gone.
6. While zoomed it and firing at the sentry gun. The game crashed when I got hit and I hit the sentry at the same time.
7. Mixing of lights vs. alpha items seems to be off. First, here is an illustration of what I mean:

Here you can see that the light get cut off on the shadow. The one that is included with the car model.
You can also see that the light is not mixed the correct way on the car. The lights seems to be suppressed, rather than adding values to the resulting image.
Here is another example. The one in green is photoshopped to illustrate (kind of) what I expected to happen:

As you can also see, the red section shows that other added objects doesn't mix properly. They totally dominate their environment.
Also, the light shadow volumes doesn't properly trace model edges. As can be seen in the image above, the lights seems to have an issue when they are close to meshes. The edge tracing for the shadow volume seems to be incorrect. You can see how the light shines through the mesh, and a distance away begin to trace the shadow.
Maybe there is a setting to control this?
Here is another example to make it more clear. Here you can clearly see that the objects I am talking about totally dominate the scene. Here I added rain, and made the droplets huge in size. Because I wanted to test if they indeed ended up 'behind' the darker objects. This image also includes a comparison with 1.1. I loaded the scene into version 1.1 and the light behaves as expected there. Obviously the dark objects have been updated for 1.2 and thus don't load in 1.1. However, the light is not mixed in a faint fashion in 1.1.

8. The convex hull (hitbox) is catching the effects of the explosions etc..

9. Setting texture quality to low, causes the flares to disappear.
10. Shadows are clipped
11. Shooting at the ejected bullet casing in flight causes damage to the player.
Making this happen is very hard, since you have to actually hit the casing. But I found it easiest when shooting
at the ground moving backwards and rotating to the right. It is also possible that it's not the bullet casing at all, but rather that I actually manage to shoot myself while moving around. Please note that I am talking about the machine gun, not the grenade launcher etc..
Video sample:
Here is a video of the issues 7,8,10 and also other shadow issues
(Note: The video says 'out' but that is just the name of the video :), just click and it will play.)
#22
in game/scripts/client.cs I changed it to this
in default.bind.cs changed it to this...
in game/scripts/server/commands.cs I added....
now set zoomreticle in weapons datablock to whatever reticle you want when zoomed....
01/25/2014 (1:17 pm)
for issue 5, heres how i did it to get my zoom reticles....in game/scripts/client.cs I changed it to this
function clientCmdRefreshWeaponHUD(%amount, %preview, %ret, %zoomRet, %amountInClips)
{
if (!%amount)
AmmoAmount.setVisible(false);
else
{
AmmoAmount.setVisible(true);
AmmoAmount.setText("Ammo: " @ %amount @ "/" @ %amountInClips);
}
if (%preview $= "")
WeaponHUD.setVisible(false);//PreviewImage.setVisible(false);
else
{
WeaponHUD.setVisible(true);//PreviewImage.setVisible(true);
PreviewImage.setbitmap("art/gui/weaponHud/"@ detag(%preview));
}
if (%ret $= "")
Reticle.setVisible(false);
else
{
Reticle.setVisible(true);
Reticle.setbitmap("art/gui/weaponHud/"@ detag(%ret));
}
}
// ----------------------------------------------------------------------------
// Zoom reticle
// ----------------------------------------------------------------------------
// Here we turn the normal reticle off and show the zoom reticle. The "reticle"
// parameter is the "zoomReticle" field in the weapon's datablock.
function clientCmdsetZoom(%reticle)
{
$ZoomOn = true;
setFov($Pref::Player::CurrentFOV);
zoomReticle.setBitmap("art/gui/weaponHud/"@ detag(%reticle));
Reticle.setVisible(false);
zoomReticle.setVisible(true);
}
function clientCmdUnSetZoom(%reticle)
{
$ZoomOn = false;
setFov($Pref::Player::defaultFOV);
Reticle.setVisible(true);
zoomReticle.setVisible(false);
}in default.bind.cs changed it to this...
function turnOffZoom()
{
$ZoomOn = false;
ServerConnection.zoomed = false;
setFov(ServerConnection.getControlCameraDefaultFov());
Reticle.setVisible(true);
zoomReticle.setVisible(false);
// Rather than just disable the DOF effect, we want to set it to the level's
// preset values.
DOFPostEffect.disable();
//ppOptionsUpdateDOFSettings();
}
function setZoomFOV(%val)
{
if(%val)
toggleZoomFOV();
}
function toggleZoom(%val)
{
if (%val)
{
if (!$ZoomOn)
commandToServer('getZoomReticle');
ServerConnection.zoomed = true;
setFov($Player::CurrentFOV);
//Reticle.setVisible(false);
//zoomReticle.setVisible(true);
//DOFPostEffect.setAutoFocus( true );
//DOFPostEffect.setFocusParams( 0.5, 0.5, 50, 500, -5, 5 );
//DOFPostEffect.enable();
DOFPostEffect.disable(); // ADDED
}
else
{
turnOffZoom();
}
}
function mouseButtonZoom(%val)
{
toggleZoom(%val);
}in game/scripts/server/commands.cs I added....
// ----------------------------------------------------------------------------
// Zoom reticle
// ----------------------------------------------------------------------------
function serverCmdgetZoomReticle(%client)
{
%player = %client.player;
%weapon = (%player.getMountedImage($WeaponSlot) == 0) ? "" : %player.getMountedImage($WeaponSlot).item;
%reticle = %weapon $= "" ? 'scopelens.png' : %weapon.zoomReticle;
commandToClient(%client, 'setZoom', %reticle);
}now set zoomreticle in weapons datablock to whatever reticle you want when zoomed....
#23
01/25/2014 (1:21 pm)
forgot just in case, in game/art/gui/playgui.cs i have this for my zoomreticle....new GuiCrossHairHud(zoomReticle) {
damageFillColor = "0 1 0 1";
damageFrameColor = "1 0.6 0 1";
damageRect = "50 4";
damageOffset = "0 10";
bitmap = "art/gui/weaponHud/sniperscope";
wrap = "0";
position = "0 0";
extent = "1024 768";
minExtent = "8 8";
horizSizing = "relative";
vertSizing = "relative";
profile = "GuiModelessDialogProfile";
visible = "0";
tooltipProfile = "GuiToolTipProfile";
hovertime = "1000";
isContainer = "0";
canSave = "1";
canSaveDynamicFields = "0";
};
Michael Tornberg
PlanetRift
are you looking into the things in this list?
I can't possibly be the only one seeing this, or?
Should I report them as bugs? Are they even bugs?
Is any of this fixable?
Richard acknowledged the decal issue, but what about the rest?
Have you seen the video?
I feel like I am being totally ignored here.