Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
VkCV Framework
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Vulkan2021
VkCV Framework
Commits
7a78a501
Commit
7a78a501
authored
3 years ago
by
Alexander Gauggel
Browse files
Options
Downloads
Patches
Plain Diff
[
#106
] Fix motion blur artifacts properly
parent
eabfdb7b
No related branches found
No related tags found
1 merge request
!89
Resolve "Indirect Dispatch"
Pipeline
#26746
passed
3 years ago
Stage: build
Stage: deploy
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
projects/indirect_dispatch/resources/shaders/motionBlurDummy.comp
+6
-2
6 additions, 2 deletions
.../indirect_dispatch/resources/shaders/motionBlurDummy.comp
with
6 additions
and
2 deletions
projects/indirect_dispatch/resources/shaders/motionBlurDummy.comp
+
6
−
2
View file @
7a78a501
...
...
@@ -14,7 +14,6 @@ layout( push_constant ) uniform constants{
float minVelocity;
};
void main(){
if(any(greaterThanEqual(gl_GlobalInvocationID.xy, imageSize(outImage))))
...
...
@@ -25,6 +24,7 @@ void main(){
vec2 uv = vec2(coord) / textureRes;
vec2 motion = texture(sampler2D(inMotion, textureSampler), uv).rg;
motion *= motionFactor;
float velocity = length(motion);
// early out on little movement
...
...
@@ -34,7 +34,11 @@ void main(){
return;
}
motion *= motionFactor;
// TODO: should be configurable by user or computed by velocity tile sizes
const float maxBlurDistance = 0.075;
if(velocity > maxBlurDistance){
motion *= maxBlurDistance / velocity;
}
vec3 color = vec3(0);
const int sampleCount = 16;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment