| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Reformulate one paragraph, as suggested by Benjamin.
|
|
|
|
| |
Avoids some trivialities and static analyis complaints.
|
| |
|
|
|
|
|
| |
Add an annotation, and tweak the docs for
gsk_gl_shader_node_new slightly.
|
|
|
|
| |
Check all that we can.
|
|
|
|
|
| |
Use a GskShaderArgsBuilder and make the parser
more precise about commas vs semicolons.
|
|
|
|
| |
Don't copy _gtk_css_print_string, just use it.
|
|
|
|
|
| |
This lets us use it from the render node parser
in gsk.
|
|
|
|
|
| |
We call it args now in the api. Follow suit for the
serialization.
|
|
|
|
| |
Mention that args are zero-initialized.
|
|
|
|
|
| |
We are not using the frame clock anymore, so don't
pass it around.
|
|
|
|
| |
Fix some types, and say a bit more here.
|
|
|
|
| |
I mixed up my variable names.
|
|
|
|
|
| |
Primarily this is ref/unref vs copy, and ne wfree_to_args() method. But
also some minor renames.
|
|
|
|
|
|
| |
Primitive values are now passed by values (although vectors still
by pointer). Also since we can now no longer handle missing definitions
that is an error.
|
|
|
|
|
|
| |
We don't want to use a new shader per paintable, because then we will
need to recompile each one. Also remove some leftover unused vars from
the cogs glsl.
|
|
|
|
|
|
|
|
|
|
| |
We now always assume you pass the right amount of children for the
shader, and each such child is followed by
gtk_snapshot_gl_shader_pop_texture() and then a final
gtk_snapshot_pop().
This means we handle the 0 child case ok, and that we can validate
that the number of pops of various types are correct.
|
|
|
|
| |
Add an example to the GskGLShader docs.
|
|
|
|
|
| |
This one tests the convenience api for creating
uniform data.
|
|
|
|
| |
This gets around 500 instances at 60fps on my system.
|
|
|
|
|
|
|
| |
Add a shader paintable to the OpenGL transitions
demo. This is reusing one of the shadertoy examples,
tweaked slightly to work as a standalone fragment
shader.
|
|
|
|
|
|
|
|
|
| |
This is a GdkPaintable implementation wrapped
around a GskGLShader. It can optionally be hooked
up to a frame clock to update a time uniform.
The code is set up for this to live as public api
in GSK, if we find it useful enough.
|
|
|
|
|
| |
We can now just use gsk_gl_shader_format_args() directly, relying
on the transfer-full of the shader args argument.
|
|
|
|
| |
This makes the common case of this just being created a lot easier.
|
|
|
|
|
| |
This makes a lot of types and function names shorter.
Also, we add a "..." version of gsk_gl_shader_format_args_va().
|
|
|
|
| |
This fixes all remaining cases in public headers.
|
|
|
|
|
|
|
|
| |
This removes the fallback node from GskGLShaderNode and adds
a new function gsk_gl_shader_try_compile_for() which tries to compile a
shader against a renderer. Then you can use the return value of this
both as a way to implement the fallback, and as a way to get at
the error report in a saner way.
|
|
|
|
|
| |
These are just basic api usage tests, no rendering.
They found the issues fixed in the preceding commits.
|
|
|
|
|
| |
Accept - in initializers, otherwise we don't accept
things like uniform int n = -2;
|
|
|
|
|
|
| |
Accept comments after a uniform declaration - the
very first shader example I tried had these, so we
better support it.
|
|
|
|
|
|
|
| |
The types we store for the uniforms are VEC2/3/4,
even though we just store a bunch of floats.
This was found while adding some simple tests.
|
|
|
|
|
|
|
| |
Print out the full assembled shader sources when
GSK_DEBUG=shaders is given. This is very verbose,
but may be useful to see what we actually pass
to the compiler.
|
|
|
|
|
|
| |
When we're done extracting uniform info from the glsl,
print out what we've found for GSK_DEBUG=shaders. If
something goes wrong, this will be useful.
|
| |
|
|
|
|
|
|
|
|
| |
Rename gtk_snapshot_push_glshader and friends to
gtk_snapshot_push_gl_shader, following the similar
renaming in GSK.
Update all callers.
|
|
|
|
| |
Tweak the gl shader docs here and there.
|
| |
|
|
|
|
| |
I was getting "assignment to varying fragColor" errors
|
|
|
|
|
|
|
|
|
|
|
| |
Add adds a demo showing off GskGLShaderNode in various ways.
It has a transistion widget, using some examples from
gl-transitions.com, with child widgets being both images, a GL area
and real widgets (that let you edit the transition shaders
themselves.
It also has a fancy fire effect on hove on the buttons.
|
|
|
|
|
|
| |
For vulkan/broadway this just means to ignore it, but for the gl
backend we support (with up to 4 texture inputs, which is similar to
what shadertoy does, so should be widely supported).
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a rendernode that is supposed to run a GLSL fragment
shader with a set of inputs and produce outputs.
The inputs are:
* A GskGLShader object with the source and uniforms definitions
computed from the source.
* A the data for the uniforms, formated according to the GskGLShader
* a list of render nodes that are rendered to textures
Additionally there is a fallback node which is used in case
OpenGL is not supported or there is some kind of failure
with the shader code.
|
|
|
|
|
|
| |
This adds a gsk prefix to the stuff in the preamble, as we want to
avoid it conflicting with things in the main shader. Especially once
we start allow some customization of shaders.
|
|
|
|
|
|
| |
Almost always the source is created by combining various sources, which
means the line numbers in the error messages are hard to use. Adding
the line numbers to the source in the error message helps with this.
|
|
|
|
|
|
| |
In gsk_gl_shader_builder_create_program(), if linking fails we
need to return -1 to indicate error, rather than the old deleted
program id.
|
|
|
|
|
|
| |
There is no real reason to have this on the side indexed via the
index, as it is stored next to each other anyway. Plus, storing them
together lets use use `Program` structures not in the array.
|
|\
| |
| |
| |
| | |
Adwaita: Improve columnview styling
See merge request GNOME/gtk!2608
|
| |
| |
| |
| | |
This should be available without .data-table.
|
| |
| |
| |
| |
| |
| |
| | |
- Move padding from parent row to child cell.
- Align horizontal sizing of cell with header button.
- Properly support GtkColumnView:show-column-separators.
- Change cell height with and without .data-table.
|
|/ |
|