Bug 10196 - specular light calculation wrong when LIGHT_MODEL_LOCAL_VIEWER is true
Summary: specular light calculation wrong when LIGHT_MODEL_LOCAL_VIEWER is true
Status: CLOSED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/i965 (show other bugs)
Version: git
Hardware: x86 (IA32) Linux (All)
: medium normal
Assignee: Eric Anholt
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-03-05 18:26 UTC by WuNian
Modified: 2009-08-24 12:26 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments
test case (2.04 KB, text/plain)
2007-03-05 18:27 UTC, WuNian
Details
re-calculating the half (1.42 KB, patch)
2007-03-07 18:50 UTC, haihao
Details | Splinter Review

Description WuNian 2007-03-05 18:26:49 UTC
If GL_LIGHT_MODEL_LOCAL_VIEWER is set to TRUE and specular light exists, the light  color calculation is incorect. Please run attached test case and refer to Light color Equation in OpenGL spec.
With i915 driver or using software rendering, the test case will pass.
Comment 1 WuNian 2007-03-05 18:27:56 UTC
Created attachment 8991 [details]
test case
Comment 2 haihao 2007-03-07 18:50:24 UTC
Created attachment 9032 [details] [review]
re-calculating the half 

According to the gl spec, the half is different from other when local view is enabled and the light is a directional source.
Comment 3 WuNian 2007-03-08 00:37:08 UTC
The patch works for us.

Please remove the content in patch: 
diff --git a/configs/default b/configs/default....
Comment 4 haihao 2007-03-08 19:28:06 UTC
Could anyone review this fix? If no problem, I will check in it.
Comment 5 Roland Scheidegger 2007-03-09 05:05:12 UTC
Looks good to me. Should probably be fixed in t_vp_build.c (used by other drivers) too (though I have to admit last time I did some changes there I missed the i965 driver because I didn't realize it has the same code).
Comment 6 haihao 2007-03-11 16:39:52 UTC
fixed. commit 61ec23cc63a040a2edf1bc466917e85362514c89
thanks for Roland's review and comments
Comment 7 Adam Jackson 2009-08-24 12:26:06 UTC
Mass version move, cvs -> git


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.