merging trunk
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/hilnius@13392 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
commit
1b5c6fd804
@ -2,25 +2,20 @@
|
||||
// Creates a cone lightbeam effect by smoothing edges
|
||||
// Original idea: http://udn.epicgames.com/Three/VolumetricLightbeamTutorial.html
|
||||
// TODO: Soft edges when it intesects geometry
|
||||
// Some artefacts are still visible
|
||||
|
||||
// Some artefacts are still visible
|
||||
|
||||
uniform sampler2D main_texture;
|
||||
uniform sampler2D tex;
|
||||
uniform float transparency;
|
||||
|
||||
varying vec2 uv;
|
||||
varying vec3 eyeVec;
|
||||
varying vec3 normal;
|
||||
|
||||
void main()
|
||||
{
|
||||
float inter = dot(normal, eyeVec);
|
||||
float m = texture2D(tex, vec2(0.5, uv.y)).r;
|
||||
float alpha = inter * inter * inter * inter * m;
|
||||
|
||||
|
||||
float inter = dot(normal, eyeVec);
|
||||
float m = texture2D(main_texture, vec2(0.5, uv.y)).r;
|
||||
|
||||
|
||||
gl_FragColor = vec4(1.0,1.0,0.8, 1.0);
|
||||
|
||||
|
||||
gl_FragColor.a = inter * inter * inter * inter * m;
|
||||
gl_FragColor = vec4(1.0, 1.0, 0.8, alpha);
|
||||
}
|
||||
|
@ -1,8 +1,6 @@
|
||||
// Jean-manuel clemencon supertuxkart
|
||||
// Creates a cone lightbeam effect by smoothing edges
|
||||
|
||||
|
||||
uniform float time;
|
||||
varying vec2 uv;
|
||||
varying vec3 eyeVec;
|
||||
varying vec3 normal;
|
||||
@ -10,13 +8,12 @@ varying vec3 normal;
|
||||
void main()
|
||||
{
|
||||
gl_TexCoord[0] = gl_MultiTexCoord0;
|
||||
gl_Position = gl_ModelViewMatrix * gl_Vertex;
|
||||
vec4 viewp = gl_ModelViewMatrix * gl_Vertex;
|
||||
|
||||
eyeVec = normalize(-viewp).xyz;
|
||||
normal = gl_NormalMatrix * gl_Normal;
|
||||
|
||||
eyeVec = normalize(-gl_Position).xyz;
|
||||
normal = gl_NormalMatrix * gl_Normal;
|
||||
gl_Position = ftransform();
|
||||
|
||||
gl_Position = ftransform();
|
||||
|
||||
uv = gl_TexCoord[0].st;
|
||||
uv = gl_TexCoord[0].st;
|
||||
}
|
||||
|
@ -6,3 +6,4 @@ The following changes have been made:
|
||||
- materialtype override
|
||||
- skies respect Z
|
||||
- partial backport to expose setCurrentRendertime in the scene mgr
|
||||
- a workaround for every other RTTs flipping
|
||||
|
@ -987,7 +987,7 @@ void COpenGLDriver::setTransform(E_TRANSFORMATION_STATE state, const core::matri
|
||||
else
|
||||
{
|
||||
GLfloat glmat[16];
|
||||
if (isRTT)
|
||||
if (isRTT && CurrentTarget == ERT_FRAME_BUFFER)
|
||||
getGLTextureMatrix(glmat, mat * TextureFlipMatrix);
|
||||
else
|
||||
getGLTextureMatrix(glmat, mat);
|
||||
|
@ -106,9 +106,9 @@ namespace Online{
|
||||
// ============================================================================
|
||||
const Server * ServersManager::getQuickPlay() const
|
||||
{
|
||||
/*if(m_sorted_servers.size() > 0)
|
||||
if(m_sorted_servers.getData().size() > 0)
|
||||
return getServerBySort(0);
|
||||
*/
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
@ -227,8 +227,16 @@ void OnlineScreen::eventCallback(Widget* widget, const std::string& name, const
|
||||
//FIXME temporary and the request join + join sequence should be placed in one method somewhere
|
||||
// refresh server list
|
||||
Online::ServersManager::RefreshRequest* request = ServersManager::get()->refreshRequest(false);
|
||||
Online::HTTPManager::get()->synchronousRequest(request);
|
||||
delete request;
|
||||
if (request != NULL) // consider request done
|
||||
{
|
||||
Online::HTTPManager::get()->synchronousRequest(request);
|
||||
delete request;
|
||||
}
|
||||
else
|
||||
{
|
||||
Log::error("OnlineScreen", "Could not get the server list.");
|
||||
return;
|
||||
}
|
||||
// select first one
|
||||
const Server * server = ServersManager::get()->getQuickPlay();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user