46 Commits

Author SHA1 Message Date
Mark Burton
f02ac17a30 GL ES compatibility fixes. 2020-05-07 13:38:09 +01:00
Remco Burema
4c4e611629
Fix x-ray error color.
X-ray errors showed as green and translucent instead of read and solid. Now fixed.
CURA-7407
2020-04-29 12:06:20 +02:00
Remco Burema
d078c465ee
Reduce branches in shader.
part of the further fallout of CURA-7147
2020-04-22 11:51:21 +02:00
Remco Burema
7ed59503d6
Round doesn't work for OpenGL 2.1 because it was only added in glsl 130.
So mad at myself right now >:-(
Part of the further fallout of CURA-7147
2020-04-22 11:49:27 +02:00
Jaime van Kessel
020f66b245
Add option to overhang shader to make rendering model errors optional
CURA-7147
2020-04-20 15:11:28 +02:00
Remco Burema
b7e6b2888a
Actually remove xray error image (because colors).
part of CURA-7262
2020-04-07 12:57:07 +02:00
Remco Burema
5494a09eef
Make sure warning works for greyscale colors.
part of CURA-7262
2020-04-07 12:46:32 +02:00
Remco Burema
b59d38e6c9
Replace warning image with triadic colors.
part of CURA-7262
2020-04-07 12:06:13 +02:00
Remco Burema
60bd676b44
Shader: More use builtin rather than adhoc mix.
part of CURA-7262
2020-04-03 21:24:35 +02:00
Remco Burema
e23b9a94fa
Shader: Use builtin rather than mix ourselves.
part of CURA-7262
2020-04-03 15:07:28 +02:00
fieldOfView
b2fc155c3b Fix legacy glsl shaders
By @smartavionics
2020-03-31 11:26:21 +02:00
fieldOfView
0794766644 Fix xray composite shader for opengl 2.1
textureSize() is not available in opengl 2.1, so we calculate the xray error image scale outside the shader (which is also a theoretical performance improvement because now the scale does not get computed over and over for each pixel)
2020-03-27 23:24:20 +01:00
Tim Kuipers
42a1b02d4c use transparency in xray view and merge shader duplication 2020-02-27 20:29:58 +01:00
Tim Kuipers
b51b699715 fix old xray view
I don't understand why it only seems to work if I define u_color via [default]
andd why it doesn't work when I set it inside the shader itself.
2020-02-27 18:17:07 +01:00
Tim Kuipers
4a8385e3e8 make xray counting color hardcoded value
Somewhere between the xray.shader and the xray_composite.shader the colors are stored as unsigned int.
Since we want to count the integer number of faces behind a pixel in the red channel, we simply use a color with an r value of 1/255.
2020-02-27 16:41:20 +01:00
Tim Kuipers
fc4c66b62a show xray errors in solid view 2020-02-27 16:41:13 +01:00
Remco Burema
9e64072b05 Older drivers can lie w.r.t. GLSL-version if it's forced lower.
... so don't use gl_PrimitiveID at all when in compatibility mode. This direct commit partly fixes github #6387 -- but see also the forthcoming PR in Uranium.
2019-09-21 14:58:59 +02:00
Diego Prado Gesto
c6f5f4fb33
Merge pull request #6308 from smartavionics/mb-fix-legacy-glsl-issue
Remove gl_PrimitiveID from shader when it's not available.
2019-09-10 17:33:02 +02:00
Remco Burema
e5a690e605 Wrap up 'lay flat by face' feature for 4.3-BETA.
Icon thanks to Yi-An Lai.
part of CURA-6754
2019-09-10 12:37:59 +02:00
Mark Burton
dffaf2f6c3 Exclude code that uses gl_PrimitiveID from shader when GLSL version < 150. 2019-09-05 10:53:15 +01:00
Remco Burema
b97015a354 Added 'align selected face with buildplate' feature.
Alt-click to select a face. See the (identically named) 'feature_bottom_face' branch in Uranium for more indepth information.
2019-09-02 00:17:14 +02:00
Remco Burema
5ea2b0e073 Make stripes closer togheter in striped shader.
part of CURA-6583
2019-07-02 16:49:27 +02:00
Remco Burema
a61e7ea7df Fix striped (off-buildplate) shader for ortho-view.
part of CURA-6583
2019-07-02 16:20:12 +02:00
Remco Burema
ed6db6c9b0 Move multiplication from Python to shaders. (Needs the same-named Uranium branch.) 2019-04-19 16:58:38 +02:00
fieldOfView
7a25841816 Fix support blocker on older (legacy) opengl 2018-05-14 14:29:41 +02:00
Jörg Walter
fa81ebeece GLES shader fixes 2018-03-29 21:07:51 +02:00
Jörg Walter
f0f768cc74 fix bool for pedantic shader compilers 2018-03-29 21:07:12 +02:00
fieldOfView
73558c9e36 Fix rendering depth pass 2018-03-13 19:44:53 +01:00
fieldOfView
0caea24afc Add depth pass for picking a location 2018-03-13 12:14:05 +01:00
fieldOfView
8bd6afad1f Render support meshes with a vertical stripe...
...so they are easier to tell apart from normal meshes, especially for single extrusion printers
2018-01-05 18:33:05 +01:00
fieldOfView
e00ac591bf Use material color for cutting_mesh and infill_mesh 2017-11-10 12:24:32 +01:00
daid
1313e01f04 Fix the OpenGL shader for older (legacy?) OpenGL. As the grid shader was no longer working. 2017-10-06 15:44:10 +02:00
fieldOfView
4c9028b3d0 Remove z-fighting kludge
This was actually introducing z-fighting artefacts with the new shader and no added geometry.
2017-09-12 15:06:06 +02:00
fieldOfView
6658e1a9ae Draw grid lines using shader 2017-09-11 23:41:10 +02:00
fieldOfView
a4aa134f25 Revert "Merge branch 'feature_grid_lines'"
This reverts commit a0b7a2d165d4f973c69bf5fc7314726f19eeeb65, reversing
changes made to db640c6f3d7b32b4c387268e8ebeb0d4de1b461a.

# Conflicts:
#	cura/BuildVolume.py
2017-09-11 22:43:55 +02:00
Ghostkeeper
585b6ad8eb
Remove superfluous grid shader
The grid shader is now exactly equal to the colour shader, so let's just use the colour shader.

Contributes to issue CURA-4150.
2017-08-17 15:25:27 +02:00
Ghostkeeper
484740f2ff
Remove grid pattern
It'll be replaced by grid lines instead of grid surfaces.

Contributes to issue CURA-4150.
2017-08-16 13:26:17 +02:00
Jack Ha
e31a695061 WIP OpenGL 4.1 core profile. CURA-3273 2017-01-31 17:05:00 +01:00
Jack Ha
fc4c60b0dc Added layer view options 2016-12-30 14:31:53 +01:00
Jack Ha
61dcaf8811 wip 2016-12-20 11:45:05 +01:00
Arjen Hiemstra
823ab61cc5 Tweak convex hull node and transparent object shader
Now we render at least a vague hint at lighting instead of nothing at
all.
2016-07-27 18:03:20 +02:00
Jack Ha
d77f6e86e4 Added an extruded convex hull as a raft instead of a grey plane.
- New shader transparent_object.shader
- Raft thickness is calculated in BuildVolume and used in
  ConvexHullDecorator, notified by a Signal.
- Removed old grey plane from BuildVolume.
- Vertex data below build plane is no longer discarded (caused convex
  hulls that are too small).
- Uses new functions in MeshBuilder (update Uranium as well).

CURA-1707
2016-07-25 16:45:38 +02:00
fieldOfView
6cc6e79e65 Stripe objects that are outside the build volume
This way they can not be confused with objects that are rendered with a (future) grey materialcolor.
2016-07-22 14:24:52 +02:00
fieldOfView
2498e7110d Allow setting the diffuse_color with a uniform binding
CURA-345
2016-06-14 11:05:50 +02:00
Arjen Hiemstra
c5689e6256 Add SolidView plugin, which is what used to be Uranium's MeshView 2015-12-14 13:56:32 +01:00
Arjen Hiemstra
7395f37efe Update BuildVolume and ConvexHullNode to use new API 2015-12-14 13:56:32 +01:00