@@ -99,18 +99,18 @@ public void ProcessImage(PostProcessingContext context, CommandBuffer cb, ref Se
99
99
cb . SetGlobalFloat ( Uniforms . _MaxBlurRadius , maxBlurPixels ) ;
100
100
101
101
int vbuffer = Uniforms . _VelocityTex ;
102
- cb . GetTemporaryRT ( vbuffer , context . width , context . height , 0 , FilterMode . Point , m_PackedRTFormat ) ;
102
+ cb . GetTemporaryRT ( vbuffer , context . width , context . height , 0 , FilterMode . Point , m_PackedRTFormat , RenderTextureReadWrite . Linear ) ;
103
103
cb . Blit ( ( Texture ) null , vbuffer , material , ( int ) Pass . VelocitySetup ) ;
104
104
105
105
// Pass 2 - First TileMax filter (1/4 downsize)
106
106
int tile4 = Uniforms . _Tile4RT ;
107
- cb . GetTemporaryRT ( tile4 , context . width / 4 , context . height / 4 , 0 , FilterMode . Point , m_VectorRTFormat ) ;
107
+ cb . GetTemporaryRT ( tile4 , context . width / 4 , context . height / 4 , 0 , FilterMode . Point , m_VectorRTFormat , RenderTextureReadWrite . Linear ) ;
108
108
cb . SetGlobalTexture ( Uniforms . _MainTex , vbuffer ) ;
109
109
cb . Blit ( vbuffer , tile4 , material , ( int ) Pass . TileMax4 ) ;
110
110
111
111
// Pass 3 - Second TileMax filter (1/2 downsize)
112
112
int tile8 = Uniforms . _Tile8RT ;
113
- cb . GetTemporaryRT ( tile8 , context . width / 8 , context . height / 8 , 0 , FilterMode . Point , m_VectorRTFormat ) ;
113
+ cb . GetTemporaryRT ( tile8 , context . width / 8 , context . height / 8 , 0 , FilterMode . Point , m_VectorRTFormat , RenderTextureReadWrite . Linear ) ;
114
114
cb . SetGlobalTexture ( Uniforms . _MainTex , tile4 ) ;
115
115
cb . Blit ( tile4 , tile8 , material , ( int ) Pass . TileMax2 ) ;
116
116
cb . ReleaseTemporaryRT ( tile4 ) ;
@@ -121,7 +121,7 @@ public void ProcessImage(PostProcessingContext context, CommandBuffer cb, ref Se
121
121
cb . SetGlobalFloat ( Uniforms . _TileMaxLoop , ( int ) ( tileSize / 8f ) ) ;
122
122
123
123
int tile = Uniforms . _TileVRT ;
124
- cb . GetTemporaryRT ( tile , context . width / tileSize , context . height / tileSize , 0 , FilterMode . Point , m_VectorRTFormat ) ;
124
+ cb . GetTemporaryRT ( tile , context . width / tileSize , context . height / tileSize , 0 , FilterMode . Point , m_VectorRTFormat , RenderTextureReadWrite . Linear ) ;
125
125
cb . SetGlobalTexture ( Uniforms . _MainTex , tile8 ) ;
126
126
cb . Blit ( tile8 , tile , material , ( int ) Pass . TileMaxV ) ;
127
127
cb . ReleaseTemporaryRT ( tile8 ) ;
@@ -130,7 +130,7 @@ public void ProcessImage(PostProcessingContext context, CommandBuffer cb, ref Se
130
130
int neighborMax = Uniforms . _NeighborMaxTex ;
131
131
int neighborMaxWidth = context . width / tileSize ;
132
132
int neighborMaxHeight = context . height / tileSize ;
133
- cb . GetTemporaryRT ( neighborMax , neighborMaxWidth , neighborMaxHeight , 0 , FilterMode . Point , m_VectorRTFormat ) ;
133
+ cb . GetTemporaryRT ( neighborMax , neighborMaxWidth , neighborMaxHeight , 0 , FilterMode . Point , m_VectorRTFormat , RenderTextureReadWrite . Linear ) ;
134
134
cb . SetGlobalTexture ( Uniforms . _MainTex , tile ) ;
135
135
cb . Blit ( tile , neighborMax , material , ( int ) Pass . NeighborMax ) ;
136
136
cb . ReleaseTemporaryRT ( tile ) ;
@@ -182,8 +182,8 @@ public void MakeRecord(CommandBuffer cb, RenderTargetIdentifier source, int widt
182
182
{
183
183
Release ( ) ;
184
184
185
- lumaTexture = RenderTexture . GetTemporary ( width , height , 0 , RenderTextureFormat . R8 ) ;
186
- chromaTexture = RenderTexture . GetTemporary ( width , height , 0 , RenderTextureFormat . R8 ) ;
185
+ lumaTexture = RenderTexture . GetTemporary ( width , height , 0 , RenderTextureFormat . R8 , RenderTextureReadWrite . Linear ) ;
186
+ chromaTexture = RenderTexture . GetTemporary ( width , height , 0 , RenderTextureFormat . R8 , RenderTextureReadWrite . Linear ) ;
187
187
188
188
lumaTexture . filterMode = FilterMode . Point ;
189
189
chromaTexture . filterMode = FilterMode . Point ;
0 commit comments