mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-05-02 08:49:20 -05:00
Merge
This commit is contained in:
@@ -22,21 +22,24 @@
|
||||
* OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. *
|
||||
****************************************************************************************/
|
||||
|
||||
// uniform vec3 color;
|
||||
#include "fragment.glsl"
|
||||
#include "floatoperations.glsl"
|
||||
|
||||
// in vec3 vs_position;
|
||||
// in vec3 vs_color;
|
||||
// in vec2 vs_texcoord;
|
||||
|
||||
// out vec4 fs_color;
|
||||
|
||||
// Fragment getFragment() {
|
||||
// Fragment frag;
|
||||
// frag.color = vec4(color, 1.f);
|
||||
// return frag;
|
||||
// }
|
||||
uniform vec3 color;
|
||||
uniform float opacity = 1.0;
|
||||
|
||||
in vec4 viewSpacePosition;
|
||||
|
||||
in vec3 vs_position;
|
||||
in vec3 vs_color;
|
||||
in vec2 vs_texcoord;
|
||||
|
||||
Fragment getFragment() {
|
||||
Fragment frag;
|
||||
frag.color = vec4(color, opacity);
|
||||
frag.gPosition = viewSpacePosition;
|
||||
return frag;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -24,20 +24,19 @@
|
||||
|
||||
#version __CONTEXT__
|
||||
|
||||
layout (location = 0) in vec3 vertex_position;
|
||||
layout (location = 1) in vec3 vertex_color;
|
||||
layout (location = 2) in vec2 vertex_texcoord;
|
||||
layout (location = 0) in vec4 vertex_data;
|
||||
|
||||
out vec3 vs_position;
|
||||
out vec3 vs_color;
|
||||
out vec2 vs_texcoord;
|
||||
uniform dmat4 modelViewTransform;
|
||||
uniform mat4 projectionTransform;
|
||||
|
||||
out vec4 viewSpacePosition;
|
||||
|
||||
void main() {
|
||||
vs_position = vertex_position;
|
||||
vs_color = vertex_color;
|
||||
vs_texcoord - vec2(vertex_texcoord.x, vertex_texcoord.y);
|
||||
|
||||
gl_Position = vec4(vertex_position, 1.f);
|
||||
dvec4 position = dvec4(vertex_data.xyz, 1.0);
|
||||
float timeOffset = vertex_data.w;
|
||||
|
||||
viewSpacePosition = vec4(modelViewTransform * position);
|
||||
gl_Position = projectionTransform * viewSpacePosition;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -28,9 +28,9 @@ layout(location = 0) in vec4 vertexData;
|
||||
|
||||
uniform dmat4 modelViewTransform;
|
||||
uniform mat4 projectionTransform;
|
||||
uniform bool useLineFade;
|
||||
uniform float lineFade;
|
||||
uniform int vertexSortingMethod;
|
||||
// uniform bool useLineFade;
|
||||
// uniform float lineFade;
|
||||
// uniform int vertexSortingMethod;
|
||||
uniform int pointSize;
|
||||
|
||||
out vec4 viewSpacePosition;
|
||||
|
||||
Reference in New Issue
Block a user