Comments (7)
Hi.
I'm already using it in Unity 2019.4.x with no problem, but I had to apply some fixes that I suggested in the pull request. I even added the ability to filter motion-blurred objects with a LayerMask field. I will push this new feature in another branch someday soon.
by the way, if you tell the exact version of the Unity you trying to use, I'll give it a try and let you know if I had any solution.
from kmotion.
Hi EsiNikko!
Thanks for your reply! I am on 2019.4.2f1 and URP 7.4.3.
I can get it to work - more or less - as per your fixes but I am not getting proper results.
Weirdly enough when I drive backwards the effects seems to work ok - when racing forward I only have the effect in the bottom right.
The camera is following the car - it is not linked or anything - it is just following it in LateUpdate.
Don't know what to check yet atm... :(
PIeter
from kmotion.
I just can't get it to work in 2019.4.12.
I have implemented the changes as suggested by EsiNikko, but the best I can get is motionblur when moving backwards. Or motionblur on the right side of the screen - but smeared to the right.
It also 'ticks' as if one frame it is rendered the other frame it is not - my guess is that this is related to my camera being updated in fixedUpdate.
Long story short - this seems to be the best solution for object motion blur for urp at the moment - but it is a bit fiddly to get to work
from kmotion.
This is the effect I currently have - this happens when the camera is moving forward.
Anyone?
from kmotion.
I have this setup using @EsiNikko branch and while it does work somewhat I can probably report the same issue as PpHammer. I spin an object in a circle and during 3/4 of the rotation the motion blur works but during one quarter the object is not blurred at all. It seems dependent on the view direction of the camera as it is always the same part of the rotation (lower right part of the circle, towards the camera).
Unity 2019.4.16f1 - URP 7.5.3
from kmotion.
I looked into the code and the reason why it's doing this is probably because the velocity texture is using RGBA32 when it should be using RGFloat.
To fix this, in MotionVectorRenderPass.cs after line 49, add :
cameraTextureDescriptor.colorFormat = RenderTextureFormat.RGFloat;
Also in MotionVector.shader, change line 20 to this:
TEXTURE2D_FLOAT(_MotionVectorTexture); SAMPLER(sampler_MotionVectorTexture);
from kmotion.
Over on EsiNikko's and my fork we fixed that texture format issue and a bunch of smaller other issues as well. Additionally to the RGFloat format (which isn't supported on many mobiles devices I've heard, probably the reason it was a more regular one) you have to change the shader to (un-)pack it correctly and when clearing the texture clear it with 0.5 instead of zero.
from kmotion.
Related Issues (10)
- 2019.3.0f6 editor crashes HOT 7
- Doesn't support srp batching
- Shader error after import HOT 2
- Help needed HOT 3
- 2019.3.0f6 Conflict with camera Post Processing flag HOT 1
- 2019.3.0f6 Wrong motion blur on objects that is attached to the camera HOT 1
- Does not working :[ HOT 9
- Couldn't make it work with Unity 2019.3.2f1 HOT 1
- Does Kmotion surport Skinned Mesh Render?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kmotion.