-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Please provide resolution as vec2 to the shader #4
Comments
Have tried to just add uniform vec2 screen; else the uv you can find in most of raymarched shader correspond to the v of VLS (and so you probably don't need the resolution :) |
Hey @lamogui, thanks for your reply. Unfortunately, the solution you proposed doesn't work. Btw. the shader I'm talking about here is [1] https://www.shadertoy.com/view/MsVfz1 You're right, that in most cases I can just use v and assign it to uv of ShaderToy sources. This is the case when ShaderToy sources have a line like this (see [1] line 845):
I can do
and in case of [1] modified it a bit to have a "better" view:
Unfortunately though, this didn't work out well with a line like this (see [1] line 978 here uv is re-assigned):
If I do
I get a checkerboarded output: My workaround until now is:
which worked - but I didn't like the approach. Your proposal using uniform vec2 screen (even though the sources of VLS don't hint at it being ever sent to the shader):
or even
didn't work at all: black screen. |
you can try uv = v *2.0 - 1.0 |
Hi,
while porting more shadertoy shaders to VLS, I found that in VLS the resolution information is missing in the shader.
While looking for clues in the VLS sources, I saw that you provide it for m_postFX as "screen" (renderwidget.cpp line 165).
As I'm unable to compile VLS myself, could you please add the resolution info to a new VLS binary release?
The text was updated successfully, but these errors were encountered: