View Issue Details

IDProjectCategoryView StatusLast Update
0004942The Dark ModGraphicspublic09.01.2019 02:34
Reporterstgatilov Assigned Tostgatilov  
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product VersionTDM 2.07 
Target VersionTDM 2.07Fixed in VersionTDM 2.07 
Summary0004942: White sparklies on the corners of objects
DescriptionSometimes there are small white pixels on the edge of very dark objects.
These pixels frequently change when you rotate camera or move around.
Steps To Reproduce1) "Run Crucible of Omens: BCD" mission
2) Execute: setviewpos 4679.81 -2072.08 604 48.0 114.1 0.0
3) Slowly rotate camera around.

You should see small white pixels appearing and disappearing.
Note that this happens even with antialiasing off.
TagsNo tags attached.

Relationships

has duplicate 0004704 closedstgatilov Shimmering Light Artifacts on pier_platform Texture 

Activities

stgatilov

stgatilov

01.01.2019 17:27

developer  

bcd_sparklies.jpg (340,706 bytes)
stgatilov

stgatilov

01.01.2019 17:27

developer  

Darkmod.cfg (13,288 bytes)
stgatilov

stgatilov

01.01.2019 17:29

developer   ~0011210

I can fix it locally by setting the following line in "advancedInteraction" function:
  float fresnelTerm = pow(1.0 - max(dot(localV, RawN), 0.0), fresnelParms2.w);
Note that I have added max to dot product, otherwise the base of exponent can get quite high, which causes the sparklies.
stgatilov

stgatilov

02.01.2019 08:10

developer   ~0011216

Fixed in svn rev 15522.

Also I found that this max was present in the old ARB code:
    //---------------------------------------------------------
    // Calculate Fresnel reflectance approximation for Diffuse lighting
    //---------------------------------------------------------
    fresnelTerm.x = clamp(dot(toViewer.xyz, localNormal.xyz), 0.0, 1.0); //DP3_SAT fresnelTerm.x, toViewer, localNormal;
    fresnelTerm = (vec4(1)) - (fresnelTerm); //SUB fresnelTerm, 1, fresnelTerm;
    fresnelTerm = vec4(pow(fresnelTerm.x, fresnelParms2.w)); //POW fresnelTerm, fresnelTerm.x, fresnelParms2.w;

Issue History

Date Modified Username Field Change
01.01.2019 17:27 stgatilov New Issue
01.01.2019 17:27 stgatilov File Added: bcd_sparklies.jpg
01.01.2019 17:27 stgatilov File Added: Darkmod.cfg
01.01.2019 17:29 stgatilov Note Added: 0011210
01.01.2019 17:29 stgatilov Assigned To => stgatilov
01.01.2019 17:29 stgatilov Status new => assigned
02.01.2019 08:09 stgatilov Fixed in Version => TDM 2.07
02.01.2019 08:09 stgatilov Target Version => TDM 2.07
02.01.2019 08:10 stgatilov Note Added: 0011216
02.01.2019 08:10 stgatilov Status assigned => resolved
02.01.2019 08:10 stgatilov Resolution open => fixed
08.01.2019 22:08 nbohr1more Relationship added related to 0004704
09.01.2019 02:34 nbohr1more Relationship deleted related to 0004704
09.01.2019 02:34 nbohr1more Relationship added has duplicate 0004704