RYHPT446116&* 4 NyLq7'^P0"2@8000T IT kH Xp0 00M0f00h0 0{000Z$   000 0 @(03(0 ! P0F0)000 @0W0}0@0$0& F*0~*000&.0/0* 00020_@0u40@000;8 0q0K?0 4 (    Bx000E0 @0 0: 0L0b00zL0M0N00(0W08@HLP")=Sdv $(,04 8 <6 @N [ Dm   W W`    0 @ P) h9 lW _ W _ W _ W _ "W _ e n y  ( 8 @ P `+ bW _ !W _ (W _ (W _ 8L W "V d d q  #   W W Sq           ) 7 C N V a *k +y )( ,8 HW _ -W _ .W _ BW _ W     ( /1 Q 0( 8n W _ :W _ P  "   [ X  &  W  )9 "5F0=C WC sC C  C@ C` C C #Q32E@W>h= W _ 3zW W$W(W,DW _ 4%6GI(TH,4`G`ly  K   0 0 JJ$ 0# 0, B L[p    $ 0 0 0 0  0 0 0 0& 05 0BXiNx(,pW _  W  )9Ux@W W VW _ T( 1(9,B K Xft PCharPContextSwitchPInt32PLightTypePRenderDataTypePSceneRenderPassTypePShadowCasterTypePTextureFormatBasePUInt16PUInt32PUInt8boolfloatCD3D11_BLEND_DESCCD3D11_DEPTH_STENCIL_DESCCD3D11_RASTERIZER_DESCD3D11_DEPTH_STENCILOP_DESCD3D11_RENDER_TARGET_BLEND_DESCPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPArrayPAssetReferencePBasePClassDescriptorPClusterHeaderPClusterHeaderBasePClusterHeaderD3D11PContextVariantFoldingTablePEffectPEffectVariantPInstanceListHeaderPMaterialPMaterialSwitchPNodeContextPParameterBufferPParameterBufferBasePSamplerStatePSamplerStateBasePSamplerStateD3D11PSceneRenderPassPShaderPShaderComputeProgramPShaderComputeProgramD3D11PShaderFragmentProgramPShaderFragmentProgramD3D11PShaderGeometryProgramPShaderGeometryProgramD3D11PShaderParameterCaptureBufferLocationPShaderParameterCaptureBufferLocationSizePShaderParameterCaptureBufferLocationTypeConstantBufferPShaderParameterCaptureBufferSamplerPShaderParameterCaptureBufferTexture2DPShaderParameterCaptureBufferTextureBasePShaderParameterDefinitionPShaderPassPShaderPassBasePShaderPassD3D11PShaderPassInfoPShaderPassParameterLocationTypesBasePShaderPassParameterLocationTypesConstantBufferPShaderPassStateBasePShaderPassStateD3D11PShaderProgramBasePShaderProgramD3D11PShaderStreamDefinitionPShaderVertexProgramPShaderVertexProgramD3D11PSharrayPStreamInputDescD3D11PStreamInputLayoutD3D11PStringPTexture2DPTexture2DBasePTexture2DD3D11PTextureCommonBasem_idm_assetm_assetTypem_indexBufferSizem_vertexBufferSizem_maxTextureBufferSizem_phyreMarkerm_sizem_instanceListCountm_packedNamespaceSizem_arrayFixupSizem_arrayFixupCountm_pointerFixupSizem_pointerFixupCountm_pointerArrayFixupSizem_pointerArrayFixupCountm_pointersInArraysCountm_userFixupCountm_userFixupDataSizem_totalDataSizem_headerClassInstanceCountm_headerClassChildCountm_platformIDm_physicsEngineIDm_supportedLightMaskm_supportedShadowCasterMaskm_effectFilem_effectSourcem_effectVariantsm_supportedLightTypesm_supportedShadowCasterTypesm_contextSwitchesm_contextVariantSwitchesm_maxLightCountm_numSupportedShaderLODLevelsm_countm_elsm_effectm_switchesm_sceneRenderPassesm_sceneRenderPassLookupm_largestShaderPassCountm_tweakableShaderParameterDefinitionsm_untweakableShaderParameterDefinitionsm_tweakableParameterBufferSizem_untweakableParameterBufferSizem_classIDm_objectsSizem_arraysSizem_effectVariantm_parameterBufferm_remapFromm_remapTom_namem_valuem_packedSwitchesm_parameterBufferSizem_minFilterm_magFilterm_wrapSm_wrapTm_wrapRm_lodBiasm_maxAnisotropym_borderColorm_baseLevelm_maxLevelm_flagsm_passTypem_shadersm_entryPointsm_variantsFoldingTablem_platformsm_platformsAreIncludem_contextVariantIndexm_contextVariantVpIndexm_contextVariantFpIndexm_contextVariantGsIndexm_contextVariantCsIndexm_passesm_parameterDefinitionsForPassesm_streamDefinitionsForPassesm_parameterBufferFrequenciesRequiredm_offsetm_constantBufferLocationm_typem_unusedPointerm_texturem_parameterTypem_samplerStatem_textureBufferIndexm_dataTypem_arrayElementCountm_bufferLocm_statem_vertexParameterLocationm_fragmentParameterLocationm_geometryParameterLocationm_computeParameterLocationm_vertexTexParameterLocationm_fragmentTexParameterLocationm_geometryTexParameterLocationm_computeTexParameterLocationm_vertexProgramm_fragmentProgramm_geometryProgramm_computeProgramm_streamLocationsm_vertexEntryPointm_vertexProfilem_fragmentEntryPointm_fragmentProfilem_geometryEntryPointm_geometryProfilem_computeEntryPointm_computeProfilem_parameterLocationsm_parameterStartm_parameterCountm_rasterDescm_depthDescm_blendDescm_stencilRefAlphaToCoverageEnableIndependentBlendEnableRenderTargetDepthEnableDepthWriteMaskDepthFuncStencilEnableStencilReadMaskStencilWriteMaskFrontFaceBackFaceFillModeCullModeFrontCounterClockwiseDepthBiasDepthBiasClampSlopeScaledDepthBiasDepthClipEnableScissorEnableMultisampleEnableAntialiasedLineEnableStencilFailOpStencilDepthFailOpStencilPassOpStencilFuncBlendEnableSrcBlendDestBlendBlendOpSrcBlendAlphaDestBlendAlphaBlendOpAlphaRenderTargetWriteMaskm_importantStatem_compiledCodem_constantBufferSizem_globalConstantBufferIndexm_shaderProfilem_renderTypem_nameHashm_indexm_inputLayoutm_um_semanticm_semanticIndexm_d3dFormatm_inputSlotm_streamsm_bufferm_widthm_heightm_formatm_memoryTypem_mipmapCountm_maxMipLevelm_textureFlagsppH hh  @@PP!@@%,|t&'+  -5P0 CH0D0xpGS@Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.cgfx#materialData/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx #line 1 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" #define D_PLATFORM_D3D11x64 // Automatically generated. Do not edit. // =======================================================================================================================[COMMON DEFINES]=== #define PHYRE3X_ENABLED #if !defined(D_PLATFORM_GXM) #define h2tex3D tex3D #define h4tex2D tex2D #define h3tex2D tex2D #define h2tex2D tex2D #define h1tex2D tex2D #define h4texCUBE texCUBE #define h3texCUBE texCUBE #endif // ========================================================================================================================[COMMON STATES]=== #if !defined(D_PLATFORM_GXM) BlendState ourBlendState { BlendEnable[0] = FALSE; BlendEnable[1] = FALSE; SrcBlend[0] = Src_Alpha; DestBlend[0] = Inv_Src_Alpha; BlendOp[0] = ADD; SrcBlendAlpha[0] = ONE; DestBlendAlpha[0] = ONE; BlendOpAlpha[0] = ADD; RenderTargetWriteMask[0] = 15; AlphaToCoverageEnable = false; }; DepthStencilState ourDepthStencilState { DepthEnable=true; DepthFunc=less; StencilEnable=false; }; RasterizerState ourRasterState { CullMode=None; DepthBias=0.0f; ScissorEnable=false; MultiSampleEnable=false; DepthClipEnable=false; AntialiasedLineEnable=false; }; #endif // ==================================================================================================================[VERTEX SHADER BEGIN]=== #define main Opaque_vs_main #define IN Opaque_vs_IN #define OUT Opaque_vs_OUT #define v2f Opaque_vs_v2f #define a2v Opaque_vs_a2v // ------------------------------------------------------------------------------------------------------------------------------------------ #define GLOBAL_LEAN_AND_MEAN #line 1 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #ifndef MIGRATORY_SH #define MIGRATORY_SH //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #ifdef D_PLATFORM_D3D11x64 #define D_PLATFORM_D3D11 #endif #ifdef D_PLATFORM_D3D11 //#pragma pack_matrix(column_major) #define D_D3D11_OTHER(x,y) x #define D_D3D11_ONLY(x) x #define POSITION_OUT SV_POSITION #define FINAL_COLOR D_D3D11_OTHER(SV_TARGET0,COLOR) #elif defined(D_PLATFORM_GNM) #ifdef __ORBIS__ #pragma warning (disable:5203) // parameter unreferenced #pragma warning (disable:5206) // local variable unreferenced #pragma warning (disable:6204) // does not support uniform default values #pragma warning (disable:6459) // __user_defined__ is not a valid semantic for uniform #pragma warning (disable:5581) // PSSL treats 'half' type as 'float' #pragma warning (disable:5609) // PSSL treats 'half' type as 'float' #pragma warning (disable:5583) // PSSL treats 'half' literals as 'float' #pragma warning (disable:5524) // unsupported compiler hint //! Some evil #defines to sort out matrix multiplies. #define float4x4 row_major float4x4 #define float3x4 row_major float3x4 #define float4x3 row_major float4x3 //! Semantics for VS/PS inputs and outputs. #define POSITION S_POSITION #define SV_POSITION S_POSITION #define SV_GroupID S_GROUP_ID #define SV_VertexID S_VERTEX_ID #define SV_DispatchThreadID S_DISPATCH_THREAD_ID #define SV_GroupThreadID S_GROUP_THREAD_ID #define SV_GroupIndex S_GROUP_INDEX #define SV_PRIMITIVEID S_PRIMITIVE_ID #define SV_IsFrontFace S_FRONT_FACE #define SV_Depth FRAG_OUTPUT_DEPTH #define FRAG_OUTPUT_COLOR S_TARGET_OUTPUT0 #define FRAG_OUTPUT_COLOR0 S_TARGET_OUTPUT0 #define FRAG_OUTPUT_COLOR1 S_TARGET_OUTPUT1 #define FRAG_OUTPUT_COLOR2 S_TARGET_OUTPUT2 #define FRAG_OUTPUT_COLOR3 S_TARGET_OUTPUT3 #define FRAG_OUTPUT_DEPTH S_DEPTH_OUTPUT //! Some defines to make textures compile with PSSL for now (sort out later) SamplerState globalSamplerState; SamplerComparisonState globalSamplerComparisonState { // Sampler state Filter = MIN_MAG_LINEAR_MIP_POINT; AddressU = CLAMP; AddressV = CLAMP; // Sampler comparison state ComparisonFunc = LESS; ComparisonFilter = COMPARISON_MIN_MAG_LINEAR_MIP_POINT; }; #define cbuffer ConstantBuffer #define sampler SamplerState #define sampler2D Texture2D #define sampler3D Texture3D #define samplerCUBE TextureCube #define tex2Dproj(a,b) a.Sample(globalSamplerState, (b).xy / (b).w) #define h1tex2Dproj(a,b) ((half)(a.Sample(globalSamplerState, (b).xy / (b).w).x)) #define h4tex2D(a,b) ((half4)a.Sample(globalSamplerState, (b).xy)) #define h4tex2Dlod(a,b) ((half4)a.SampleLOD(globalSamplerState, (b).xy, (b).w)) #define tex2D(a,b) a.Sample(globalSamplerState, (b).xy) #define SampleLevel SampleLOD #define SampleCmpLevelZero SampleCmpLOD0 #define StructuredBuffer RegularBuffer #define RWStructuredBuffer RW_RegularBuffer #define numthreads NUM_THREADS #define maxvertexcount MAX_VERTEX_COUNT #define groupshared thread_group_memory #define TriangleStream TriangleBuffer #define PointStream PointBuffer #define triangle Triangle #define IncrementCounter IncrementCount #define DecrementCounter DecrementCount #define GroupMemoryBarrierWithGroupSync ThreadGroupMemoryBarrierSync #define InterlockedMin AtomicMin #define InterlockedMax AtomicMax #define InterlockedAdd AtomicAdd #endif //! __ORBIS__ #if defined(PHYRE_D3DFX) && !defined(__ORBIS__) #define FRAG_OUTPUT_COLOR SV_TARGET #define FRAG_OUTPUT_COLOR0 SV_TARGET0 #define FRAG_OUTPUT_COLOR1 SV_TARGET1 #define FRAG_OUTPUT_COLOR2 SV_TARGET2 #define FRAG_OUTPUT_COLOR3 SV_TARGET3 #define FRAG_OUTPUT_DEPTH SV_DEPTH #define SYSTEM_PRIMITIVE_INDEX SV_PRIMITIVEID #endif //! defined(PHYRE_D3DFX) && !defined(__ORBIS__) #define D_D3D11_OTHER(x,y) x #define D_D3D11_ONLY(x) x #define POSITION_OUT POSITION #define FINAL_COLOR FRAG_OUTPUT_COLOR #else #define D_D3D11_OTHER(x,y) y #define D_D3D11_ONLY(x) #define HALF half #define HALF2 half2 #define HALF3 half3 #define HALF4 half4 #define HALF3x3 float3x3 #define HALF3x4 float3x4 #define HALF4x4 float4x4 #define POSITION_OUT POSITION #define FINAL_COLOR D_D3D11_OTHER(SV_TARGET0,COLOR) #endif #if defined(__psp2__) #define NATIVECOLOR __nativecolor #define REGFORMAT __regformat #else #define NATIVECOLOR #define REGFORMAT #endif #if !defined(__ORBIS__) && !defined(D_PLATFORM_GXM) BlendState NoBlend_BlendState { BlendEnable[0] = FALSE; }; BlendState Alpha_BlendState { BlendEnable[0] = TRUE; SrcBlend[0] = Src_Alpha; DestBlend[0] = Inv_Src_Alpha; BlendOp[0] = ADD; SrcBlendAlpha[0] = Src_Alpha; DestBlendAlpha[0] = Inv_Src_Alpha; BlendOpAlpha[0] = ADD; BlendEnable[1] = FALSE; }; BlendState Additive_BlendState { BlendEnable[0] = TRUE; SrcBlend[0] = Src_Alpha; DestBlend[0] = ONE; BlendOp[0] = ADD; SrcBlendAlpha[0] = Src_Alpha; DestBlendAlpha[0] = ONE; BlendOpAlpha[0] = ADD; BlendEnable[1] = FALSE; }; BlendState ParticleBlended_BlendState { BlendEnable[0] = TRUE; SrcBlend[0] = ONE; DestBlend[0] = Inv_Src_Alpha; BlendOp[0] = ADD; SrcBlendAlpha[0] = ONE; DestBlendAlpha[0] = Inv_Src_Alpha; BlendOpAlpha[0] = ADD; BlendEnable[1] = FALSE; }; DepthStencilState NoDepthTest_NoDepthWrite_DepthState { DepthEnable = FALSE; DepthWriteMask = Zero; DepthFunc = Less; StencilEnable = FALSE; }; DepthStencilState NoDepthTest_DepthWrite_DepthState { DepthEnable = FALSE; DepthWriteMask = All; DepthFunc = Less; StencilEnable = FALSE; }; DepthStencilState DepthTest_NoDepthWrite_DepthState { DepthEnable = TRUE; DepthWriteMask = Zero; DepthFunc = Less; StencilEnable = FALSE; }; DepthStencilState DepthTest_DepthWrite_DepthState { DepthEnable = TRUE; DepthWriteMask = All; DepthFunc = Less; StencilEnable = FALSE; }; RasterizerState NoCull_RasterizerState { CullMode=None; }; RasterizerState BackFaceCull_RasterizerState { CullMode=Back; FrontCounterClockwise = TRUE; }; RasterizerState FrontFaceCull_RasterizerState { CullMode=Front; FrontCounterClockwise = TRUE; }; #endif #if defined(D_PLATFORM_D3D11) || defined(D_PLATFORM_GNM) #define MatrixMul(a,b) mul(b,a) #define HALF float #define HALF2 float2 #define HALF3 float3 #define HALF4 float4 #define HALF3x3 float3x3 #define HALF3x4 float3x4 #define HALF4x4 float4x4 #define half float #define half2 float2 #define half3 float3 #define half4 float4 #else #define MatrixMul(a,b) mul(a,b) #endif // samplers #if defined(D_PLATFORM_D3D11) || defined(D_PLATFORM_GNM) sampler PointClampSampler : register(s8) { Filter = Min_Mag_Mip_Point; AddressU = Clamp; AddressV = Clamp; AddressW = Clamp; }; sampler LinearClampSampler : register(s9) { Filter = Min_Mag_Mip_Linear; AddressU = Clamp; AddressV = Clamp; AddressW = Clamp; }; sampler LinearWrapTSampler : register(s10) { Filter = Min_Mag_Mip_Linear; AddressU = Clamp; AddressV = Wrap; AddressW = Clamp; }; sampler LinearWrapSampler : register(s11) { Filter = Min_Mag_Mip_Linear; AddressU = Wrap; AddressV = Wrap; AddressW = Wrap; }; sampler PointWrapSampler : register(s12) { Filter = Min_Mag_Mip_Point; AddressU = Wrap; AddressV = Wrap; AddressW = Wrap; }; sampler AnisoClampSampler : register(s13) { Filter = ANISOTROPIC; AddressU = Clamp; AddressV = Clamp; AddressW = Clamp; MaxAnisotropy = 16; }; sampler LinearWrapAnisoSampler : register(s14) { Filter = ANISOTROPIC; AddressU = Wrap; AddressV = Wrap; AddressW = Wrap; MaxAnisotropy = 16; }; sampler PointWrapAnisoSampler : register(s15) { Filter = Min_Mag_Point_Mip_Linear; AddressU = Wrap; AddressV = Wrap; AddressW = Wrap; MaxAnisotropy = 16; }; #define SAMPLER_WRAP_ANISO LinearWrapAnisoSampler #define SAMPLER_WRAP_LINEAR LinearWrapSampler #define SAMPLER_WRAP_POINT PointWrapSampler #define SAMPLER_CLAMP_ANISO AnisoClampSampler #define SAMPLER_CLAMP_LINEAR LinearClampSampler #define SAMPLER_CLAMP_POINT PointClampSampler static const float kSRGB = 2.2f; #define SRGB_ON(x) pow(x,kSRGB) #define SRGB_OFF(x) x #define SAMPLETEX(tex,uv,filter,wrap,srgb) SRGB_##srgb(tex.Sample(SAMPLER_##wrap##_##filter, uv)) #ifdef __ORBIS__ #define D_DECLARE_TEXTURE2DMS_4(x) MS_Texture2D x #else #define D_DECLARE_TEXTURE2DMS_4(x) Texture2DMS x #endif #define D_DECLARE_TEXTURE2D_4(x) Texture2D x #define D_DECLARE_TEXTURE3D_4(x) Texture3D x #define D_DECLARE_TEXTURE_CUBE_4(x) TextureCube x #define D_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_POINT_SAMPLE_TEXTURE(tex,uv) tex.Sample(PointClampSampler,uv) #define D_SAMPLE_TEXTURE_PROJ(tex,uv) tex.Sample(LinearClampSampler,(float2) (uv.xy / uv.w) ) #define D_POINT_SAMPLE_TEXTURE_PROJ(tex,uv) tex.Sample(PointClampSampler,(float2) (uv.xy / uv.w) ) #define D_SAMPLE_TEXTURE_3D(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_SAMPLE_TEXTURE_WRAP_3D(tex,uv) tex.Sample(LinearWrapSampler,uv) #define D_H1_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).x #define D_H2_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).xy #define D_H3_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).xyz #define D_H4_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_H1_POINTSAMPLELEVEL_TEXTURE(tex,uv,lod) tex.SampleLevel(PointClampSampler,uv,lod).x #define D_H1_SAMPLELEVEL_TEXTURE(tex,uv,lod) tex.SampleLevel(LinearClampSampler,uv,lod).x #define D_H4_SAMPLELEVEL_TEXTURE(tex,uv,lod) tex.SampleLevel(LinearClampSampler,uv,lod) #if defined(D_PLATFORM_D3D11) #define D_H1_SAMPLE_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearClampSampler,uv).x,2.2f) #define D_H2_SAMPLE_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearClampSampler,uv).xy,2.2f) #define D_H3_SAMPLE_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f) #define D_H4_SAMPLE_SRGBTEXTURE(tex,uv) float4( pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f), tex.Sample(LinearClampSampler,uv).a ) #define D_H1_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearWrapSampler,uv).x,2.2f) #define D_H2_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearWrapSampler,uv).xy,2.2f) #define D_H3_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearWrapSampler,uv).xyz,2.2f) #define D_H4_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) float4( pow(tex.Sample(LinearWrapSampler,uv).xyz,2.2f), tex.Sample(LinearWrapSampler,uv).a ) #define D_H4_SAMPLE_WRAPT_SRGBTEXTURE(tex,uv) float4( pow(tex.Sample(LinearWrapTSampler,uv).xyz,2.2f), tex.Sample(LinearWrapTSampler,uv).a) #define D_H3_SAMPLE_WRAP_ANISO_SRGBTEXTURE(tex,uv) pow( tex.Sample(LinearWrapAnisoSampler,uv).xyz, 2.2f) #else #define D_H1_SAMPLE_SRGBTEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).x #define D_H2_SAMPLE_SRGBTEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).xy #define D_H3_SAMPLE_SRGBTEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).xyz #define D_H4_SAMPLE_SRGBTEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_H1_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).x #define D_H2_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).xy #define D_H3_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).xyz #define D_H4_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv) #define D_H4_SAMPLE_WRAPT_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapTSampler,uv) #endif #define D_H1_SAMPLE_WRAP_TEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).x #define D_H2_SAMPLE_WRAP_TEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).xy #define D_H3_SAMPLE_WRAP_TEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).xyz #define D_H4_SAMPLE_WRAP_TEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv) #define D_H1_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(LinearWrapAnisoSampler,uv).x #define D_H2_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(LinearWrapAnisoSampler,uv).xy #define D_H3_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(LinearWrapAnisoSampler,uv).xyz #define D_H4_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(LinearWrapAnisoSampler,uv) #define D_H1_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(PointWrapAnisoSampler,uv).x #define D_H2_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(PointWrapAnisoSampler,uv).xy #define D_H3_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(PointWrapAnisoSampler,uv).xyz #define D_H4_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(PointWrapAnisoSampler,uv) #define D_H2_SAMPLE_TEXTURE_3D(tex,uv) tex.Sample(LinearClampSampler,uv).xy #define D_H2_SAMPLE_WRAP_TEXTURE_3D(tex,uv) tex.Sample(LinearWrapSampler,uv).xy #if defined(D_PLATFORM_D3D11) #define D_H3_SAMPLE_TEXTURE_CUBE(tex,uv) pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f) #define D_H4_SAMPLE_TEXTURE_CUBE(tex,uv) float4( pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f), tex.Sample(LinearClampSampler,uv).a ) #define D_SAMPLE_TEXTURE_CUBE(tex,uv) float4( pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f), tex.Sample(LinearClampSampler,uv).a ) #else #define D_H3_SAMPLE_TEXTURE_CUBE(tex,uv) tex.Sample(LinearClampSampler,uv).xyz #define D_H4_SAMPLE_TEXTURE_CUBE(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_SAMPLE_TEXTURE_CUBE(tex,uv) tex.Sample(LinearClampSampler,uv) #endif #else #define D_DECLARE_TEXTURE2D_4(x) sampler2D x #define D_DECLARE_TEXTURE3D_4(x) sampler3D x #define D_DECLARE_TEXTURE_CUBE_4(x) samplerCUBE x #define D_SAMPLE_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_POINT_SAMPLE_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_SAMPLE_TEXTURE_PROJ(tex,uv) h4tex2Dproj(tex,uv.xyw) #define D_POINT_SAMPLE_TEXTURE_PROJ(tex,uv) h4tex2Dproj(tex,uv.xyw) #define D_SAMPLE_TEXTURE_CUBE(tex,uv) h4texCUBE(tex,uv) #define D_SAMPLE_TEXTURE_3D(tex,uv) h4tex3D(tex,uv) #define D_SAMPLE_TEXTURE_WRAP_3D(tex,uv) h4tex3D(tex,uv) #define D_H1_SAMPLE_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_POINTSAMPLELEVEL_TEXTURE(tex,uv,lod) h1tex2D(tex,uv).x #define D_H1_SAMPLELEVEL_TEXTURE(tex,uv,lod) h1tex2D(tex,uv).x #define D_H4_SAMPLELEVEL_TEXTURE(tex,uv,lod) h4tex2D(tex,uv) #define D_H1_SAMPLE_SRGBTEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_SRGBTEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_SRGBTEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_SRGBTEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_WRAP_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_WRAP_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_WRAP_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_WRAP_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_ANISO_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_ANISO_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_ANISO_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_ANISO_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H4_SAMPLE_WRAPT_SRGBTEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H2_SAMPLE_TEXTURE_3D(tex,uv) h2tex3D(tex,uv).xy #define D_H2_SAMPLE_WRAP_TEXTURE_3D(tex,uv) h2tex3D(tex,uv).xy #define D_H3_SAMPLE_TEXTURE_CUBE(tex,uv) h3texCUBE(tex,uv).xyz #define D_H4_SAMPLE_TEXTURE_CUBE(tex,uv) h4texCUBE(tex,uv) #endif #if !defined(GLOBAL_LEAN_AND_MEAN) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // these constants are system constants; uploaded by Phyre itself. // we can't do this, but we don't want to upload them all the time, either. consequently, we make these global // i guess we can eventually stuff these into a separate uniform buffer //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// float4x4 view : view ; // uploaded once per camera float4x4 projection : projection ; // view inverse float4x4 viewprojection : viewprojection ; float4 eyeDirectionWS : eyeDirectionWS ; float4 eyePositionWS : eyePositionWS ; float4 eyePositionOS : eyePositionOS ; float4 cameraNear : cameraNearFar ; float4x4 modelIT : modelit ; // uploaded per primitive // model inverse transpose float4x4 model : model ; float4x4 modelViewProj : modelviewproj ; #endif //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // depth conversion code, stolen from the sample code //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// float cameraNearTimesFar; float cameraFarMinusNear; float4 cameraNearFar; // Convert a depth value from post projection space to view space. float ConvertDepth(float depth) { // float viewSpaceZ = -(scene.cameraNearTimesFar / (depth * scene.cameraFarMinusNear - scene.cameraNearFar.y)); #if defined(D_PLATFORM_GXM) float viewSpaceZ = -(cameraNearTimesFar / (depth * cameraFarMinusNear - cameraNearFar.y)); #else float viewSpaceZ = -(cameraNearTimesFar / (depth * cameraFarMinusNear - cameraNearFar.y)); #endif return viewSpaceZ; } //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // skinning //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #ifdef SKINNING_ENABLED // grabbed off [PhyreCoreShaderShared.h] // Description: // Encapsulates the skinning transformation matrices. #if defined(D_PLATFORM_GXM) #define PE_MAX_SKIN_CB_TRANSFORMS 32 float4x4 boneTransforms[PE_MAX_SKIN_CB_TRANSFORMS]; float4x4 GenerateBoneMatrix(int4 SkinIndices,float4 SkinWeights) { return boneTransforms[SkinIndices[0]]*SkinWeights[0] + boneTransforms[SkinIndices[1]]*SkinWeights[1] + boneTransforms[SkinIndices[2]]*SkinWeights[2] + boneTransforms[SkinIndices[3]]*SkinWeights[3]; } #else #define PE_MAX_SKIN_CB_TRANSFORMS 32 struct PSkinTransforms { float4x4 Mtxs[PE_MAX_SKIN_CB_TRANSFORMS]; // The skinning transformation matrices. }; cbuffer BoneTransformConstantBuffer { PSkinTransforms SkinTransforms; } float4x4 GenerateBoneMatrix(uint4 SkinIndices,float4 SkinWeights) { return SkinTransforms.Mtxs[SkinIndices[0]]*SkinWeights[0] + SkinTransforms.Mtxs[SkinIndices[1]]*SkinWeights[1] + SkinTransforms.Mtxs[SkinIndices[2]]*SkinWeights[2] + SkinTransforms.Mtxs[SkinIndices[3]]*SkinWeights[3]; } #endif #endif //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// static const float4x4 SCALE_BIAS = float4x4( float4( 0.5, 0.0, 0.0, 0.5 ), #if defined(D_PLATFORM_D3D11) float4( 0.0, -0.5, 0.0, 0.5 ), #else float4( 0.0, 0.5, 0.0, 0.5 ), #endif float4( 0.0, 0.0, 0.5, 0.5 ), float4( 0.0, 0.0, 0.0, 1.0 ) ); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #ifdef D_PLATFORM_GXM #define D_INT_MOD(val,mod) (frac((floor((float)val)/mod))*mod) #define D_UINT_MOD(val,mod) (frac((floor((float)val)/mod))*mod) #elif defined(D_PLATFORM_GNM) #define D_INT_MOD(val,mod) ((int)floor(val) % mod) #define D_UINT_MOD(val,mod) ((uint)floor(val) % mod) #else #define D_INT_MOD(val,mod) ((int)floor(val) % mod) #define D_UINT_MOD(val,mod) ((int)floor(val) % mod) #endif //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #ifdef D_ENABLE_DEBUG_PARAMS float4 debugVars0; float4 debugVars1; float4 debugVars2; float4 debugVars3; float4 debugVars4; float4 debugVars5; float4 debugVars6; float4 debugVars7; #define GETDEBUGVAR(dv) (debugVars##dv!=0) ? (debugVars##dv) : #define GETDEBUGVAR2(dv,scl) (debugVars##dv!=0) ? (scl*debugVars##dv) : #endif #define powsafe(_x,_y) pow(max(_x,0.00000000000001),_y) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #endif//MIGRATORY_SH #line 54 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" struct IN { #if defined(__ORBIS__) float4 position : POSITION; #else float3 position : POSITION; #endif #if defined(TEXTURE_UVW) float3 uv : TEXCOORD0; #else float2 uv : TEXCOORD0; #endif }; struct OUT { float4 position : POSITION_OUT; #if defined(TEXTURE_UVW) float3 uv : TEXCOORD0; #else float2 uv : TEXCOORD0; #endif }; //---------------------------------------------- // Resample // - Requires input coords in clip space // Doesn't do any real work, just meant // for resampling (for example, for blurs) //---------------------------------------------- void main( IN input, out OUT output ) { #if defined(D_PLATFORM_D3D11) output.position = float4(input.position.x,-input.position.y, input.position.z, 1); #else output.position = float4(input.position.xyz,1); #endif output.uv = input.uv; }// ------------------------------------------------------------------------------------------------------------------------------------------ #undef main #undef IN #undef OUT #undef v2f #undef a2v // ===================================================================================================================[PIXEL SHADER BEGIN]=== #define main Opaque_fs_main #define IN Opaque_fs_IN #define OUT Opaque_fs_OUT #define v2f Opaque_fs_v2f #define f2f Opaque_fs_f2f // ------------------------------------------------------------------------------------------------------------------------------------------ #line 1 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #ifndef MIGRATORY_SH #define MIGRATORY_SH //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #ifdef D_PLATFORM_D3D11x64 #define D_PLATFORM_D3D11 #endif #ifdef D_PLATFORM_D3D11 //#pragma pack_matrix(column_major) #define D_D3D11_OTHER(x,y) x #define D_D3D11_ONLY(x) x #define POSITION_OUT SV_POSITION #define FINAL_COLOR D_D3D11_OTHER(SV_TARGET0,COLOR) #elif defined(D_PLATFORM_GNM) #ifdef __ORBIS__ #pragma warning (disable:5203) // parameter unreferenced #pragma warning (disable:5206) // local variable unreferenced #pragma warning (disable:6204) // does not support uniform default values #pragma warning (disable:6459) // __user_defined__ is not a valid semantic for uniform #pragma warning (disable:5581) // PSSL treats 'half' type as 'float' #pragma warning (disable:5609) // PSSL treats 'half' type as 'float' #pragma warning (disable:5583) // PSSL treats 'half' literals as 'float' #pragma warning (disable:5524) // unsupported compiler hint //! Some evil #defines to sort out matrix multiplies. #define float4x4 row_major float4x4 #define float3x4 row_major float3x4 #define float4x3 row_major float4x3 //! Semantics for VS/PS inputs and outputs. #define POSITION S_POSITION #define SV_POSITION S_POSITION #define SV_GroupID S_GROUP_ID #define SV_VertexID S_VERTEX_ID #define SV_DispatchThreadID S_DISPATCH_THREAD_ID #define SV_GroupThreadID S_GROUP_THREAD_ID #define SV_GroupIndex S_GROUP_INDEX #define SV_PRIMITIVEID S_PRIMITIVE_ID #define SV_IsFrontFace S_FRONT_FACE #define SV_Depth FRAG_OUTPUT_DEPTH #define FRAG_OUTPUT_COLOR S_TARGET_OUTPUT0 #define FRAG_OUTPUT_COLOR0 S_TARGET_OUTPUT0 #define FRAG_OUTPUT_COLOR1 S_TARGET_OUTPUT1 #define FRAG_OUTPUT_COLOR2 S_TARGET_OUTPUT2 #define FRAG_OUTPUT_COLOR3 S_TARGET_OUTPUT3 #define FRAG_OUTPUT_DEPTH S_DEPTH_OUTPUT //! Some defines to make textures compile with PSSL for now (sort out later) SamplerState globalSamplerState; SamplerComparisonState globalSamplerComparisonState { // Sampler state Filter = MIN_MAG_LINEAR_MIP_POINT; AddressU = CLAMP; AddressV = CLAMP; // Sampler comparison state ComparisonFunc = LESS; ComparisonFilter = COMPARISON_MIN_MAG_LINEAR_MIP_POINT; }; #define cbuffer ConstantBuffer #define sampler SamplerState #define sampler2D Texture2D #define sampler3D Texture3D #define samplerCUBE TextureCube #define tex2Dproj(a,b) a.Sample(globalSamplerState, (b).xy / (b).w) #define h1tex2Dproj(a,b) ((half)(a.Sample(globalSamplerState, (b).xy / (b).w).x)) #define h4tex2D(a,b) ((half4)a.Sample(globalSamplerState, (b).xy)) #define h4tex2Dlod(a,b) ((half4)a.SampleLOD(globalSamplerState, (b).xy, (b).w)) #define tex2D(a,b) a.Sample(globalSamplerState, (b).xy) #define SampleLevel SampleLOD #define SampleCmpLevelZero SampleCmpLOD0 #define StructuredBuffer RegularBuffer #define RWStructuredBuffer RW_RegularBuffer #define numthreads NUM_THREADS #define maxvertexcount MAX_VERTEX_COUNT #define groupshared thread_group_memory #define TriangleStream TriangleBuffer #define PointStream PointBuffer #define triangle Triangle #define IncrementCounter IncrementCount #define DecrementCounter DecrementCount #define GroupMemoryBarrierWithGroupSync ThreadGroupMemoryBarrierSync #define InterlockedMin AtomicMin #define InterlockedMax AtomicMax #define InterlockedAdd AtomicAdd #endif //! __ORBIS__ #if defined(PHYRE_D3DFX) && !defined(__ORBIS__) #define FRAG_OUTPUT_COLOR SV_TARGET #define FRAG_OUTPUT_COLOR0 SV_TARGET0 #define FRAG_OUTPUT_COLOR1 SV_TARGET1 #define FRAG_OUTPUT_COLOR2 SV_TARGET2 #define FRAG_OUTPUT_COLOR3 SV_TARGET3 #define FRAG_OUTPUT_DEPTH SV_DEPTH #define SYSTEM_PRIMITIVE_INDEX SV_PRIMITIVEID #endif //! defined(PHYRE_D3DFX) && !defined(__ORBIS__) #define D_D3D11_OTHER(x,y) x #define D_D3D11_ONLY(x) x #define POSITION_OUT POSITION #define FINAL_COLOR FRAG_OUTPUT_COLOR #else #define D_D3D11_OTHER(x,y) y #define D_D3D11_ONLY(x) #define HALF half #define HALF2 half2 #define HALF3 half3 #define HALF4 half4 #define HALF3x3 float3x3 #define HALF3x4 float3x4 #define HALF4x4 float4x4 #define POSITION_OUT POSITION #define FINAL_COLOR D_D3D11_OTHER(SV_TARGET0,COLOR) #endif #if defined(__psp2__) #define NATIVECOLOR __nativecolor #define REGFORMAT __regformat #else #define NATIVECOLOR #define REGFORMAT #endif #if !defined(__ORBIS__) && !defined(D_PLATFORM_GXM) BlendState NoBlend_BlendState { BlendEnable[0] = FALSE; }; BlendState Alpha_BlendState { BlendEnable[0] = TRUE; SrcBlend[0] = Src_Alpha; DestBlend[0] = Inv_Src_Alpha; BlendOp[0] = ADD; SrcBlendAlpha[0] = Src_Alpha; DestBlendAlpha[0] = Inv_Src_Alpha; BlendOpAlpha[0] = ADD; BlendEnable[1] = FALSE; }; BlendState Additive_BlendState { BlendEnable[0] = TRUE; SrcBlend[0] = Src_Alpha; DestBlend[0] = ONE; BlendOp[0] = ADD; SrcBlendAlpha[0] = Src_Alpha; DestBlendAlpha[0] = ONE; BlendOpAlpha[0] = ADD; BlendEnable[1] = FALSE; }; BlendState ParticleBlended_BlendState { BlendEnable[0] = TRUE; SrcBlend[0] = ONE; DestBlend[0] = Inv_Src_Alpha; BlendOp[0] = ADD; SrcBlendAlpha[0] = ONE; DestBlendAlpha[0] = Inv_Src_Alpha; BlendOpAlpha[0] = ADD; BlendEnable[1] = FALSE; }; DepthStencilState NoDepthTest_NoDepthWrite_DepthState { DepthEnable = FALSE; DepthWriteMask = Zero; DepthFunc = Less; StencilEnable = FALSE; }; DepthStencilState NoDepthTest_DepthWrite_DepthState { DepthEnable = FALSE; DepthWriteMask = All; DepthFunc = Less; StencilEnable = FALSE; }; DepthStencilState DepthTest_NoDepthWrite_DepthState { DepthEnable = TRUE; DepthWriteMask = Zero; DepthFunc = Less; StencilEnable = FALSE; }; DepthStencilState DepthTest_DepthWrite_DepthState { DepthEnable = TRUE; DepthWriteMask = All; DepthFunc = Less; StencilEnable = FALSE; }; RasterizerState NoCull_RasterizerState { CullMode=None; }; RasterizerState BackFaceCull_RasterizerState { CullMode=Back; FrontCounterClockwise = TRUE; }; RasterizerState FrontFaceCull_RasterizerState { CullMode=Front; FrontCounterClockwise = TRUE; }; #endif #if defined(D_PLATFORM_D3D11) || defined(D_PLATFORM_GNM) #define MatrixMul(a,b) mul(b,a) #define HALF float #define HALF2 float2 #define HALF3 float3 #define HALF4 float4 #define HALF3x3 float3x3 #define HALF3x4 float3x4 #define HALF4x4 float4x4 #define half float #define half2 float2 #define half3 float3 #define half4 float4 #else #define MatrixMul(a,b) mul(a,b) #endif // samplers #if defined(D_PLATFORM_D3D11) || defined(D_PLATFORM_GNM) sampler PointClampSampler : register(s8) { Filter = Min_Mag_Mip_Point; AddressU = Clamp; AddressV = Clamp; AddressW = Clamp; }; sampler LinearClampSampler : register(s9) { Filter = Min_Mag_Mip_Linear; AddressU = Clamp; AddressV = Clamp; AddressW = Clamp; }; sampler LinearWrapTSampler : register(s10) { Filter = Min_Mag_Mip_Linear; AddressU = Clamp; AddressV = Wrap; AddressW = Clamp; }; sampler LinearWrapSampler : register(s11) { Filter = Min_Mag_Mip_Linear; AddressU = Wrap; AddressV = Wrap; AddressW = Wrap; }; sampler PointWrapSampler : register(s12) { Filter = Min_Mag_Mip_Point; AddressU = Wrap; AddressV = Wrap; AddressW = Wrap; }; sampler AnisoClampSampler : register(s13) { Filter = ANISOTROPIC; AddressU = Clamp; AddressV = Clamp; AddressW = Clamp; MaxAnisotropy = 16; }; sampler LinearWrapAnisoSampler : register(s14) { Filter = ANISOTROPIC; AddressU = Wrap; AddressV = Wrap; AddressW = Wrap; MaxAnisotropy = 16; }; sampler PointWrapAnisoSampler : register(s15) { Filter = Min_Mag_Point_Mip_Linear; AddressU = Wrap; AddressV = Wrap; AddressW = Wrap; MaxAnisotropy = 16; }; #define SAMPLER_WRAP_ANISO LinearWrapAnisoSampler #define SAMPLER_WRAP_LINEAR LinearWrapSampler #define SAMPLER_WRAP_POINT PointWrapSampler #define SAMPLER_CLAMP_ANISO AnisoClampSampler #define SAMPLER_CLAMP_LINEAR LinearClampSampler #define SAMPLER_CLAMP_POINT PointClampSampler static const float kSRGB = 2.2f; #define SRGB_ON(x) pow(x,kSRGB) #define SRGB_OFF(x) x #define SAMPLETEX(tex,uv,filter,wrap,srgb) SRGB_##srgb(tex.Sample(SAMPLER_##wrap##_##filter, uv)) #ifdef __ORBIS__ #define D_DECLARE_TEXTURE2DMS_4(x) MS_Texture2D x #else #define D_DECLARE_TEXTURE2DMS_4(x) Texture2DMS x #endif #define D_DECLARE_TEXTURE2D_4(x) Texture2D x #define D_DECLARE_TEXTURE3D_4(x) Texture3D x #define D_DECLARE_TEXTURE_CUBE_4(x) TextureCube x #define D_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_POINT_SAMPLE_TEXTURE(tex,uv) tex.Sample(PointClampSampler,uv) #define D_SAMPLE_TEXTURE_PROJ(tex,uv) tex.Sample(LinearClampSampler,(float2) (uv.xy / uv.w) ) #define D_POINT_SAMPLE_TEXTURE_PROJ(tex,uv) tex.Sample(PointClampSampler,(float2) (uv.xy / uv.w) ) #define D_SAMPLE_TEXTURE_3D(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_SAMPLE_TEXTURE_WRAP_3D(tex,uv) tex.Sample(LinearWrapSampler,uv) #define D_H1_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).x #define D_H2_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).xy #define D_H3_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).xyz #define D_H4_SAMPLE_TEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_H1_POINTSAMPLELEVEL_TEXTURE(tex,uv,lod) tex.SampleLevel(PointClampSampler,uv,lod).x #define D_H1_SAMPLELEVEL_TEXTURE(tex,uv,lod) tex.SampleLevel(LinearClampSampler,uv,lod).x #define D_H4_SAMPLELEVEL_TEXTURE(tex,uv,lod) tex.SampleLevel(LinearClampSampler,uv,lod) #if defined(D_PLATFORM_D3D11) #define D_H1_SAMPLE_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearClampSampler,uv).x,2.2f) #define D_H2_SAMPLE_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearClampSampler,uv).xy,2.2f) #define D_H3_SAMPLE_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f) #define D_H4_SAMPLE_SRGBTEXTURE(tex,uv) float4( pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f), tex.Sample(LinearClampSampler,uv).a ) #define D_H1_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearWrapSampler,uv).x,2.2f) #define D_H2_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearWrapSampler,uv).xy,2.2f) #define D_H3_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) pow(tex.Sample(LinearWrapSampler,uv).xyz,2.2f) #define D_H4_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) float4( pow(tex.Sample(LinearWrapSampler,uv).xyz,2.2f), tex.Sample(LinearWrapSampler,uv).a ) #define D_H4_SAMPLE_WRAPT_SRGBTEXTURE(tex,uv) float4( pow(tex.Sample(LinearWrapTSampler,uv).xyz,2.2f), tex.Sample(LinearWrapTSampler,uv).a) #define D_H3_SAMPLE_WRAP_ANISO_SRGBTEXTURE(tex,uv) pow( tex.Sample(LinearWrapAnisoSampler,uv).xyz, 2.2f) #else #define D_H1_SAMPLE_SRGBTEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).x #define D_H2_SAMPLE_SRGBTEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).xy #define D_H3_SAMPLE_SRGBTEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv).xyz #define D_H4_SAMPLE_SRGBTEXTURE(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_H1_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).x #define D_H2_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).xy #define D_H3_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).xyz #define D_H4_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv) #define D_H4_SAMPLE_WRAPT_SRGBTEXTURE(tex,uv) tex.Sample(LinearWrapTSampler,uv) #endif #define D_H1_SAMPLE_WRAP_TEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).x #define D_H2_SAMPLE_WRAP_TEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).xy #define D_H3_SAMPLE_WRAP_TEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv).xyz #define D_H4_SAMPLE_WRAP_TEXTURE(tex,uv) tex.Sample(LinearWrapSampler,uv) #define D_H1_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(LinearWrapAnisoSampler,uv).x #define D_H2_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(LinearWrapAnisoSampler,uv).xy #define D_H3_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(LinearWrapAnisoSampler,uv).xyz #define D_H4_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(LinearWrapAnisoSampler,uv) #define D_H1_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(PointWrapAnisoSampler,uv).x #define D_H2_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(PointWrapAnisoSampler,uv).xy #define D_H3_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(PointWrapAnisoSampler,uv).xyz #define D_H4_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) tex.Sample(PointWrapAnisoSampler,uv) #define D_H2_SAMPLE_TEXTURE_3D(tex,uv) tex.Sample(LinearClampSampler,uv).xy #define D_H2_SAMPLE_WRAP_TEXTURE_3D(tex,uv) tex.Sample(LinearWrapSampler,uv).xy #if defined(D_PLATFORM_D3D11) #define D_H3_SAMPLE_TEXTURE_CUBE(tex,uv) pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f) #define D_H4_SAMPLE_TEXTURE_CUBE(tex,uv) float4( pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f), tex.Sample(LinearClampSampler,uv).a ) #define D_SAMPLE_TEXTURE_CUBE(tex,uv) float4( pow(tex.Sample(LinearClampSampler,uv).xyz,2.2f), tex.Sample(LinearClampSampler,uv).a ) #else #define D_H3_SAMPLE_TEXTURE_CUBE(tex,uv) tex.Sample(LinearClampSampler,uv).xyz #define D_H4_SAMPLE_TEXTURE_CUBE(tex,uv) tex.Sample(LinearClampSampler,uv) #define D_SAMPLE_TEXTURE_CUBE(tex,uv) tex.Sample(LinearClampSampler,uv) #endif #else #define D_DECLARE_TEXTURE2D_4(x) sampler2D x #define D_DECLARE_TEXTURE3D_4(x) sampler3D x #define D_DECLARE_TEXTURE_CUBE_4(x) samplerCUBE x #define D_SAMPLE_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_POINT_SAMPLE_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_SAMPLE_TEXTURE_PROJ(tex,uv) h4tex2Dproj(tex,uv.xyw) #define D_POINT_SAMPLE_TEXTURE_PROJ(tex,uv) h4tex2Dproj(tex,uv.xyw) #define D_SAMPLE_TEXTURE_CUBE(tex,uv) h4texCUBE(tex,uv) #define D_SAMPLE_TEXTURE_3D(tex,uv) h4tex3D(tex,uv) #define D_SAMPLE_TEXTURE_WRAP_3D(tex,uv) h4tex3D(tex,uv) #define D_H1_SAMPLE_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_POINTSAMPLELEVEL_TEXTURE(tex,uv,lod) h1tex2D(tex,uv).x #define D_H1_SAMPLELEVEL_TEXTURE(tex,uv,lod) h1tex2D(tex,uv).x #define D_H4_SAMPLELEVEL_TEXTURE(tex,uv,lod) h4tex2D(tex,uv) #define D_H1_SAMPLE_SRGBTEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_SRGBTEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_SRGBTEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_SRGBTEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_WRAP_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_WRAP_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_WRAP_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_WRAP_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_WRAP_ANISO_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_ANISO_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_ANISO_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_ANISO_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_ANISO_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_POINT_WRAP_ANISO_TEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H1_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) h1tex2D(tex,uv).x #define D_H2_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) h2tex2D(tex,uv).xy #define D_H3_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) h3tex2D(tex,uv).xyz #define D_H4_SAMPLE_WRAP_SRGBTEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H4_SAMPLE_WRAPT_SRGBTEXTURE(tex,uv) h4tex2D(tex,uv) #define D_H2_SAMPLE_TEXTURE_3D(tex,uv) h2tex3D(tex,uv).xy #define D_H2_SAMPLE_WRAP_TEXTURE_3D(tex,uv) h2tex3D(tex,uv).xy #define D_H3_SAMPLE_TEXTURE_CUBE(tex,uv) h3texCUBE(tex,uv).xyz #define D_H4_SAMPLE_TEXTURE_CUBE(tex,uv) h4texCUBE(tex,uv) #endif #if !defined(GLOBAL_LEAN_AND_MEAN) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // these constants are system constants; uploaded by Phyre itself. // we can't do this, but we don't want to upload them all the time, either. consequently, we make these global // i guess we can eventually stuff these into a separate uniform buffer //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// float4x4 view : view ; // uploaded once per camera float4x4 projection : projection ; // view inverse float4x4 viewprojection : viewprojection ; float4 eyeDirectionWS : eyeDirectionWS ; float4 eyePositionWS : eyePositionWS ; float4 eyePositionOS : eyePositionOS ; float4 cameraNear : cameraNearFar ; float4x4 modelIT : modelit ; // uploaded per primitive // model inverse transpose float4x4 model : model ; float4x4 modelViewProj : modelviewproj ; #endif //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // depth conversion code, stolen from the sample code //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// float cameraNearTimesFar; float cameraFarMinusNear; float4 cameraNearFar; // Convert a depth value from post projection space to view space. float ConvertDepth(float depth) { // float viewSpaceZ = -(scene.cameraNearTimesFar / (depth * scene.cameraFarMinusNear - scene.cameraNearFar.y)); #if defined(D_PLATFORM_GXM) float viewSpaceZ = -(cameraNearTimesFar / (depth * cameraFarMinusNear - cameraNearFar.y)); #else float viewSpaceZ = -(cameraNearTimesFar / (depth * cameraFarMinusNear - cameraNearFar.y)); #endif return viewSpaceZ; } //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // skinning //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #ifdef SKINNING_ENABLED // grabbed off [PhyreCoreShaderShared.h] // Description: // Encapsulates the skinning transformation matrices. #if defined(D_PLATFORM_GXM) #define PE_MAX_SKIN_CB_TRANSFORMS 32 float4x4 boneTransforms[PE_MAX_SKIN_CB_TRANSFORMS]; float4x4 GenerateBoneMatrix(int4 SkinIndices,float4 SkinWeights) { return boneTransforms[SkinIndices[0]]*SkinWeights[0] + boneTransforms[SkinIndices[1]]*SkinWeights[1] + boneTransforms[SkinIndices[2]]*SkinWeights[2] + boneTransforms[SkinIndices[3]]*SkinWeights[3]; } #else #define PE_MAX_SKIN_CB_TRANSFORMS 32 struct PSkinTransforms { float4x4 Mtxs[PE_MAX_SKIN_CB_TRANSFORMS]; // The skinning transformation matrices. }; cbuffer BoneTransformConstantBuffer { PSkinTransforms SkinTransforms; } float4x4 GenerateBoneMatrix(uint4 SkinIndices,float4 SkinWeights) { return SkinTransforms.Mtxs[SkinIndices[0]]*SkinWeights[0] + SkinTransforms.Mtxs[SkinIndices[1]]*SkinWeights[1] + SkinTransforms.Mtxs[SkinIndices[2]]*SkinWeights[2] + SkinTransforms.Mtxs[SkinIndices[3]]*SkinWeights[3]; } #endif #endif //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// static const float4x4 SCALE_BIAS = float4x4( float4( 0.5, 0.0, 0.0, 0.5 ), #if defined(D_PLATFORM_D3D11) float4( 0.0, -0.5, 0.0, 0.5 ), #else float4( 0.0, 0.5, 0.0, 0.5 ), #endif float4( 0.0, 0.0, 0.5, 0.5 ), float4( 0.0, 0.0, 0.0, 1.0 ) ); //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #ifdef D_PLATFORM_GXM #define D_INT_MOD(val,mod) (frac((floor((float)val)/mod))*mod) #define D_UINT_MOD(val,mod) (frac((floor((float)val)/mod))*mod) #elif defined(D_PLATFORM_GNM) #define D_INT_MOD(val,mod) ((int)floor(val) % mod) #define D_UINT_MOD(val,mod) ((uint)floor(val) % mod) #else #define D_INT_MOD(val,mod) ((int)floor(val) % mod) #define D_UINT_MOD(val,mod) ((int)floor(val) % mod) #endif //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #ifdef D_ENABLE_DEBUG_PARAMS float4 debugVars0; float4 debugVars1; float4 debugVars2; float4 debugVars3; float4 debugVars4; float4 debugVars5; float4 debugVars6; float4 debugVars7; #define GETDEBUGVAR(dv) (debugVars##dv!=0) ? (debugVars##dv) : #define GETDEBUGVAR2(dv,scl) (debugVars##dv!=0) ? (scl*debugVars##dv) : #endif #define powsafe(_x,_y) pow(max(_x,0.00000000000001),_y) //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// #endif//MIGRATORY_SH #line 108 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" // Notes: A small kernel blur that does a max instead of a blend. // This is used to "pull out" the near DoF intensities // a la Modern Warfare. // // Author: John Edwards // Date C: 3-21-2011 #define ourBlendState NoBlend_BlendState #define ourDepthStencilState NoDepthTest_NoDepthWrite_DepthState #define ourRasterState NoCull_RasterizerState struct v2f { float4 position : POSITION_OUT; float2 uv : TEXCOORD0; }; struct f2f { float4 color : FINAL_COLOR; }; float4 pixelSize; D_DECLARE_TEXTURE2D_4(tex); //---------------------------------------------- // Program entry //---------------------------------------------- void main( v2f IN, out f2f OUT ) { const float2 kOffsets[9] = { float2( 0.0, 0.0 ) , float2( 1.0, 0.0 ) , float2(-1.0, 0.0 ) , float2( 0.0, 1.0 ) , float2( 0.0,-1.0 ) , float2( 1.0, 1.0 ) , float2(-1.0, 1.0 ) , float2(-1.0,-1.0 ) , float2( 1.0,-1.0 ) }; OUT.color.a = 0; for( int i = 0; i < 9; i++ ) { float2 uv = IN.uv + kOffsets[ i ] * pixelSize.xy; OUT.color.a = max( OUT.color.a, D_SAMPLE_TEXTURE( tex, uv ).a ); } } // ------------------------------------------------------------------------------------------------------------------------------------------ #undef main #undef IN #undef OUT #undef v2f #undef f2f // ===================================================================================================================[TECHNIQUE CODE END]=== #if !defined(D_PLATFORM_GXM) #ifndef __ORBIS__ technique11 Opaque { pass pass0 { SetVertexShader( CompileShader( vs_5_0, Opaque_vs_main() ) ); SetPixelShader( CompileShader( ps_5_0, Opaque_fs_main() ) ); SetBlendState(ourBlendState, float4( 0.0f, 0.0f, 0.0f, 0.0f ), 0xFFFFFFFF); SetDepthStencilState(ourDepthStencilState,0); SetRasterizerState(ourRasterState); } } #endif #else technique Opaque { pass pass0 { VertexProgram = compile arbvp1 Opaque_vs_main(); FragmentProgram = compile arbfp1 Opaque_fs_main(); } } #endif D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx   GGGGGGGG?????AA? Pt005spDXBC]zhTV՗t8tRDEF4<A RD11< ($   LinearClampSamplertex$Globals0t cameraNearTimesFarfloatcameraFarMinusNearcameraNearFarfloat4pixelSizeMicrosoft (R) HLSL Shader Compiler 10.1ISGNP8DSV_POSITIONTEXCOORDOSGN, SV_TARGETSHEXPjYF Z` XpUUb2e hi 6 20 @6 20 @?6 20 @6 20 @?6 20 @6 20 @??6 20 @?6 20 @6 20 @?+@6"@6B 60":@  62F0 :82FF 2FFECUF6y` 4B* :@6 *>STAT SPDBnMicrosoft C/C++ MSF 7.00 DS768 <.1c^kYF٥5kQ3ndAlpha [ 0 ] = ONE ; DestBlendAlpha [ 0 ] = ONE ; BlendOpAlpha [ 0 ] = ADD ; RenderTargetWriteMask [ 0 ] = 15 ; AlphaToCoverageEnable = false ; } ; DepthStencilState ourDepthStencilState { DepthEnable = true ; DepthFunc = less ; StencilEnable = false ; } ; RasterizerState ourRasterState { CullMode = None ; DepthBias = 0.0f ; ScissorEnable = false ; MultiSampleEnable = false ; DepthClipEnable = false ; AntialiasedLineEnable = false ; } Zu}dPh&S!AA$5VU8ʳ#line 1 "D:\\Dev\\TGC\\Journey\\head\\Journey\\Data\\Shaders\\S_Resample_vs__NearDofBlur_fs__0.fx" #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" #line 4 BlendState ourBlendState { BlendEnable [ 0 ] = FALSE ; BlendEnable [ 1 ] = FALSE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = ONE ; DestBlendAlpha [ 0 ] = ONE ; BlendOpAlpha [ 0 ] = ADD ; RenderTargetWriteMask [ 0 ] = 15 ; AlphaToCoverageEnable = false ; } ; DepthStencilState ourDepthStencilState { DepthEnable = true ; DepthFunc = less ; StencilEnable = false ; } ; RasterizerState ourRasterState { CullMode = None ; DepthBias = 0.0f ; ScissorEnable = false ; MultiSampleEnable = false ; DepthClipEnable = false ; AntialiasedLineEnable = false ; } ; #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #line 8 #line 16 #line 20 #line 135 #line 140 #line 147 BlendState NoBlend_BlendState { BlendEnable [ 0 ] = FALSE ; } ; BlendState Alpha_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = Src_Alpha ; DestBlendAlpha [ 0 ] = Inv_Src_Alpha ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; BlendState Additive_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = ONE ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = Src_Alpha ; DestBlendAlpha [ 0 ] = ONE ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; #line 180 BlendState ParticleBlended_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = ONE ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = ONE ; DestBlendAlpha [ 0 ] = Inv_Src_Alpha ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; DepthStencilState NoDepthTest_NoDepthWrite_DepthState { DepthEnable = FALSE ; DepthWriteMask = Zero ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState NoDepthTest_DepthWrite_DepthState { DepthEnable = FALSE ; DepthWriteMask = All ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState DepthTest_NoDepthWrite_DepthState { DepthEnable = TRUE ; DepthWriteMask = Zero ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState DepthTest_DepthWrite_DepthState { DepthEnable = TRUE ; DepthWriteMask = All ; DepthFunc = Less ; StencilEnable = FALSE ; } ; RasterizerState NoCull_RasterizerState { CullMode = None ; } ; RasterizerState BackFaceCull_RasterizerState { CullMode = Back ; FrontCounterClockwise = TRUE ; } ; RasterizerState FrontFaceCull_RasterizerState { CullMode = Front ; FrontCounterClockwise = TRUE ; } ; #line 243 #line 246 #line 264 #line 269 sampler PointClampSampler : register ( s8 ) { Filter = Min_Mag_Mip_Point ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; } ; sampler LinearClampSampler : register ( s9 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; } ; sampler LinearWrapTSampler : register ( s10 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Clamp ; AddressV = Wrap ; AddressW = Clamp ; } ; sampler LinearWrapSampler : register ( s11 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; } ; sampler PointWrapSampler : register ( s12 ) { Filter = Min_Mag_Mip_Point ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; } ; sampler AnisoClampSampler : register ( s13 ) { Filter = ANISOTROPIC ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; MaxAnisotropy = 16 ; } ; sampler LinearWrapAnisoSampler : register ( s14 ) { Filter = ANISOTROPIC ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; MaxAnisotropy = 16 ; } ; sampler PointWrapAnisoSampler : register ( s15 ) { Filter = Min_Mag_Point_Mip_Linear ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; MaxAnisotropy = 16 ; } ; static const float kSRGB = 2.2f ; #line 358 #line 373 #line 408 #line 427 #line 435 #line 498 #line 516 #line 521 float cameraNearTimesFar ; float cameraFarMinusNear ; float4 cameraNearFar ; #line 527 float ConvertDepth ( float depth ) { #line 532 float viewSpaceZ = - ( cameraNearTimesFar / ( depth * cameraFarMinusNear - cameraNearFar . y ) ) ; return viewSpaceZ ; } #line 587 #line 592 static const float4x4 SCALE_BIAS = float4x4 ( float4 ( 0.5 , 0.0 , 0.0 , 0.5 ) , float4 ( 0.0 , - 0.5 , 0.0 , 0.5 ) , #line 598 float4 ( 0.0 , 0.0 , 0.5 , 0.5 ) , float4 ( 0.0 , 0.0 , 0.0 , 1.0 ) ) ; #line 613 #line 635 #line 642 #line 53 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" struct Opaque_vs_IN { #line 59 float3 position : POSITION ; #line 64 float2 uv : TEXCOORD0 ; } ; struct Opaque_vs_OUT { float4 position : SV_POSITION ; #line 74 float2 uv : TEXCOORD0 ; } ; #line 85 void Opaque_vs_main ( Opaque_vs_IN input , out Opaque_vs_OUT output ) { output . position = float4 ( input . position . x , - input . position . y , input . position . z , 1 ) ; #line 91 output . uv = input . uv ; } #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #line 642 #line 107 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" #line 116 struct Opaque_fs_v2f { float4 position : SV_POSITION ; float2 uv : TEXCOORD0 ; } ; struct Opaque_fs_f2f { float4 color : SV_TARGET0 ; } ; float4 pixelSize ; Texture2D < float4 > tex ; #line 138 void Opaque_fs_main ( Opaque_fs_v2f Opaque_fs_IN , out Opaque_fs_f2f Opaque_fs_OUT ) { const float2 kOffsets [ 9 ] = { float2 ( 0.0 , 0.0 ) , float2 ( 1.0 , 0.0 ) , float2 ( - 1.0 , 0.0 ) , float2 ( 0.0 , 1.0 ) , float2 ( 0.0 , - 1.0 ) , float2 ( 1.0 , 1.0 ) , float2 ( - 1.0 , 1.0 ) , float2 ( - 1.0 , - 1.0 ) , float2 ( 1.0 , - 1.0 ) } ; Opaque_fs_OUT . color . a = 0 ; for ( int i = 0 ; i < 9 ; i ++ ) { float2 uv = Opaque_fs_IN . uv + kOffsets [ i ] * pixelSize . xy ; Opaque_fs_OUT . color . a = max ( Opaque_fs_OUT . color . a , tex . Sample ( LinearClampSampler , uv ) . a ) ; } } technique11 Opaque { pass pass0 { SetVertexShader ( CompileShader ( vs_5_0 , Opaque_vs_main ( ) ) ) ; SetPixelShader ( CompileShader ( ps_5_0 , Opaque_fs_main ( ) ) ) ; SetBlendState ( NoBlend_BlendState , float4 ( 0.0f , 0.0f , 0.0f , 0.0f ) , 0xFFFFFFFF ) ; SetDepthStencilState ( NoDepthTest_NoDepthWrite_DepthState , 0 ) ; SetRasterizerState ( NoCull_RasterizerState ) ; } } #line 189 }D:\Dev\TGC\Journey\head\Journey\shaderd:\dev\tgc\journey\head\journey\shader#line 1 "D:\\Dev\\TGC\\Journey\\head\\Journey\\Data\\Shaders\\S_Resample_vs__NearDofBlur_fs__0.fx" #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" #line 4 BlendState ourBlendState { BlendEnable [ 0 ] = FALSE ; BlendEnable [ 1 ] = FALSE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBle0_)(0I()B< G GMicrosoft (R) HLSL Shader Compiler 10.1^=hlslFlags0x4005hlslTargetps_5_0hlslEntryOpaque_fs_mainhlslDefines /DPHYRE_D3DFX=16lhOpaque_fs_main2> Opaque_fs_INPhPhPhP h PhPh6> Opaque_fs_OUTPhPhPhP h P (P .> kOffsetsPh*>tiP(P *>uvP,P|0h<ȑ e3Cp 2dhh  @@ dd  ((DDdd#!$$$$$$$$$ I)6 I)G IG vGn v%t" Hh 18h LLT@float4@float2& position uv"Opaque_fs_v2f color"Opaque_fs_f2f   "          18 ; #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #line 8 #line 16 #line 20 #line 135 #line 140 #line 147 BlendState NoBlend_BlendState { BlendEnable [ 0 ] = FALSE ; } ; BlendState Alpha_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = Src_Alpha ; DestBlendAlpha [ 0 ] = Inv_Src_Alpha ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; BlendState Additive_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = ONE ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = Src_Alpha ; DestBlendAlpha [ 0 ] = ONE ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; #line 180 BlendState ParticleBlended_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = ONE ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = ONE ; DestBlendAlpha [ 0 ] = Inv_Src_Alpha ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; DepthStencilState NoDepthTest_NoDepthWrite_DepthState { DepthEnable = FALSE ; DepthWriteMask = Zero ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState NoDepthTest_DepthWrite_DepthState { DepthEnable = FALSE ; DepthWriteMask = All ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState DepthTest_NoDepthWrite_DepthState { DepthEnable = TRUE ; DepthWriteMask = Zero ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState DepthTest_DepthWrite_DepthState { DepthEnable = TRUE ; DepthWriteMask = All ; DepthFunc = Less ; StencilEnable = FALSE ; } ; RasterizerState NoCull_RasterizerState { CullMode = None ; } ; RasterizerState BackFaceCull_RasterizerState { CullMode = Back ; FrontCounterClockwise = TRUE ; } ; RasterizerState FrontFaceCull_RasterizerState { CullMode = Front ; FrontCounterClockwise = TRUE ; } ; #line 243 #line 246 #line 264 #line 269 sampler PointClampSampler : register ( s8 ) { Filter = Min_Mag_Mip_Point ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; } ; sampler LinearClampSampler : register ( s9 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; } ; sampler LinearWrapTSampler : register ( s10 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Clamp ; AddressV = Wrap ; AddressW = Clamp ; } ; sampler LinearWrapSampler : register ( s11 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; } ; sampler PointWrapSampler : register ( s12 ) { Filter = Min_Mag_Mip_Point ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; } ; sampler AnisoClampSampler : register ( s13 ) { Filter = ANISOTROPIC ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; MaxAnisotropy = 16 ; } ; sampler LinearWrapAnisoSampler : register ( s14 ) { Filter = ANISOTROPIC ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; MaxAnisotropy = 16 ; } ; sampler PointWrapAnisoSampler : register ( s15 ) { Filter = Min_Mag_Point_Mip_Linear ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; MaxAnisotropy = 16 ; } ; static const float kSRGB = 2.2f ; #line 358 #line 373 #line 408 #line 427 #line 435 #line 498 #line 516 #line 521 float cameraNearTimesFar ; float cameraFarMinusNear ; float4 cameraNearFar ; #line 527 float ConvertDepth ( float depth ) { #line 532 float viewSpaceZ = - ( cameraNearTimesFar / ( depth * cameraFarMinusNear - cameraNearFar . y ) ) ; return viewSpaceZ ; } #line 587 #line 592 static const float4x4 SCALE_BIAS = float4x4 ( float4 ( 0.5 , 0.0 , 0.0 , 0.5 ) , float4 ( 0.0 , - 0.5 , 0.0 , 0.5 ) , #line 598 float4 ( 0.0 , 0.0 , 0.5 , 0.5 ) , float4 ( 0.0 , 0.0 , 0.0 , 1.0 ) ) ; #line 613 #line 635 #line 642 #line 53 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" struct Opaque_vs_IN { #line 59 float3 position : POSITION ; #line 64 float2 uv : TEXCOORD0 ; } ; struct Opaque_vs_OUT { float4 position : SV_POSITION ; #line 74 float2 uv : TEXCOORD0 ; } ; #line 85 void Opaque_vs_main ( Opaque_vs_IN input , out Opaque_vs_OUT output ) { output . position = float4 ( input . position . x , - input . position . y , input . position . z , 1 ) ; #line 91 output . uv = input . uv ; } #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #line 642 #line 107 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" #line 116 struct Opaque_fs_v2f { float4 position : SV_POSITION ; float2 uv : TEXCOORD0 ; } ; struct Opaque_fs_f2f { float4 color : SV_TARGET0 ; } ; float4 pixelSize ; Texture2D < float4 > tex ; #line 138 void Opaque_fs_main ( Opaque_fs_v2f Opaque_fs_IN , out Opaque_fs_f2f Opaque_fs_OUT ) { const float2 kOffsets [ 9 ] = { float2 ( 0.0 , 0.0 ) , float2 ( 1.0 , 0.0 ) , float2 ( - 1.0 , 0.0 ) , float2 ( 0.0 , 1.0 ) , float2 ( 0.0 , - 1.0 ) , float2 ( 1.0 , 1.0 ) , float2 ( - 1.0 , 1.0 ) , float2 ( - 1.0 , - 1.0 ) , float2 ( 1.0 , - 1.0 ) } ; Opaque_fs_OUT . color . a = 0 ; for ( int i = 0 ; i < 9 ; i ++ ) { float2 uv = Opaque_fs_IN . uv + kOffsets [ i ] * pixelSize . xy ; Opaque_fs_OUT . color . a = max ( Opaque_fs_OUT . color . a , tex . Sample ( LinearClampSampler , uv ) . a ) ; } } technique11 Opaque { pass pass0 { SetVertexShader ( CompileShader ( vs_5_0 , Opaque_vs_main ( ) ) ) ; SetPixelShader ( CompileShader ( ps_5_0 , Opaque_fs_main ( ) ) ) ; SetBlendState ( NoBlend_BlendState , float4 ( 0.0f , 0.0f , 0.0f , 0.0f ) , 0xFFFFFFFF ) ; SetDepthStencilState ( NoDepthTest_NoDepthWrite_DepthState , 0 ) ; SetRasterizerState ( NoCull_RasterizerState ) ; } } #line 189 D:\\Dev\\TGC\\Journey\\head\\Journey\\Data\\Shaders\\S_Resample_vs__NearDofBlur_fs__0.fxD:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fxD:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh (PC)D3DSHDR ` / iI!@ $%Opaque_fs_main&Q  LinearClampSamplerQ pixelSizeQtexZ /sh  ` pOpaque_fs_mainnonew 1 ?\T ,$ ` pOpaque_fs_mainnone-. `'D:\Dev\TGC\Journey\head\Journey\shaderD:\\Dev\\TGC\\Journey\\head\\Journey\\Data\\Shaders\\S_Resample_vs__NearDofBlur_fs__0.fxD:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fxD:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory..1c^kYF٥5kT/LinkInfo/names/src/headerblock/src/files/d:\dev\tgc\journey\head\journey\shader" Q3 38I@T(D,432 !"#$%&'()*+, -./1058    4444h4P48444 4444h4P4844 4@ G4G4G4G4G4G4hG4PG48B4 AnisoClampSamplerLinearClampSamplerLinearWrapAnisoSamplerLinearWrapSamplerLinearWrapTSamplerPointClampSamplerPointWrapAnisoSamplerPointWrapSamplerpixelSizetex 05sv05spOpaque_fs_mainOpaque_vs_main8j }RPOSITIONTEXCOORDp005svDXBC.U7#5؃mp8PRDEFd<A<RD11< ($ Microsoft (R) HLSL Shader Compiler 10.1ISGNL8APOSITIONTEXCOORDOSGNP8D SV_POSITIONTEXCOORDSHEXP&j_r_2g e2 6" A+ @6R 62 F>STATSPDBnMicrosoft C/C++ MSF 7.00 DS748 <.1c^*˞7C !Q3ndAlpha [ 0 ] = ONE ; DestBlendAlpha [ 0 ] = ONE ; BlendOpAlpha [ 0 ] = ADD ; RenderTargetWriteMask [ 0 ] = 15 ; AlphaToCoverageEnable = false ; } ; DepthStencilState ourDepthStencilState { DepthEnable = true ; DepthFunc = less ; StencilEnable = false ; } ; RasterizerState ourRasterState { CullMode = None ; DepthBias = 0.0f ; ScissorEnable = false ; MultiSampleEnable = false ; DepthClipEnable = false ; AntialiasedLineEnable = false ; } Luޡ\HZ9sP+#line 1 "D:\\Dev\\TGC\\Journey\\head\\Journey\\Data\\Shaders\\S_Resample_vs__NearDofBlur_fs__0.fx" #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" #line 4 BlendState ourBlendState { BlendEnable [ 0 ] = FALSE ; BlendEnable [ 1 ] = FALSE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = ONE ; DestBlendAlpha [ 0 ] = ONE ; BlendOpAlpha [ 0 ] = ADD ; RenderTargetWriteMask [ 0 ] = 15 ; AlphaToCoverageEnable = false ; } ; DepthStencilState ourDepthStencilState { DepthEnable = true ; DepthFunc = less ; StencilEnable = false ; } ; RasterizerState ourRasterState { CullMode = None ; DepthBias = 0.0f ; ScissorEnable = false ; MultiSampleEnable = false ; DepthClipEnable = false ; AntialiasedLineEnable = false ; } ; #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #line 8 #line 16 #line 20 #line 135 #line 140 #line 147 BlendState NoBlend_BlendState { BlendEnable [ 0 ] = FALSE ; } ; BlendState Alpha_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = Src_Alpha ; DestBlendAlpha [ 0 ] = Inv_Src_Alpha ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; BlendState Additive_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = ONE ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = Src_Alpha ; DestBlendAlpha [ 0 ] = ONE ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; #line 180 BlendState ParticleBlended_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = ONE ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = ONE ; DestBlendAlpha [ 0 ] = Inv_Src_Alpha ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; DepthStencilState NoDepthTest_NoDepthWrite_DepthState { DepthEnable = FALSE ; DepthWriteMask = Zero ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState NoDepthTest_DepthWrite_DepthState { DepthEnable = FALSE ; DepthWriteMask = All ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState DepthTest_NoDepthWrite_DepthState { DepthEnable = TRUE ; DepthWriteMask = Zero ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState DepthTest_DepthWrite_DepthState { DepthEnable = TRUE ; DepthWriteMask = All ; DepthFunc = Less ; StencilEnable = FALSE ; } ; RasterizerState NoCull_RasterizerState { CullMode = None ; } ; RasterizerState BackFaceCull_RasterizerState { CullMode = Back ; FrontCounterClockwise = TRUE ; } ; RasterizerState FrontFaceCull_RasterizerState { CullMode = Front ; FrontCounterClockwise = TRUE ; } ; #line 243 #line 246 #line 264 #line 269 sampler PointClampSampler : register ( s8 ) { Filter = Min_Mag_Mip_Point ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; } ; sampler LinearClampSampler : register ( s9 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; } ; sampler LinearWrapTSampler : register ( s10 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Clamp ; AddressV = Wrap ; AddressW = Clamp ; } ; sampler LinearWrapSampler : register ( s11 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; } ; sampler PointWrapSampler : register ( s12 ) { Filter = Min_Mag_Mip_Point ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; } ; sampler AnisoClampSampler : register ( s13 ) { Filter = ANISOTROPIC ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; MaxAnisotropy = 16 ; } ; sampler LinearWrapAnisoSampler : register ( s14 ) { Filter = ANISOTROPIC ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; MaxAnisotropy = 16 ; } ; sampler PointWrapAnisoSampler : register ( s15 ) { Filter = Min_Mag_Point_Mip_Linear ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; MaxAnisotropy = 16 ; } ; static const float kSRGB = 2.2f ; #line 358 #line 373 #line 408 #line 427 #line 435 #line 498 #line 516 #line 521 float cameraNearTimesFar ; float cameraFarMinusNear ; float4 cameraNearFar ; #line 527 float ConvertDepth ( float depth ) { #line 532 float viewSpaceZ = - ( cameraNearTimesFar / ( depth * cameraFarMinusNear - cameraNearFar . y ) ) ; return viewSpaceZ ; } #line 587 #line 592 static const float4x4 SCALE_BIAS = float4x4 ( float4 ( 0.5 , 0.0 , 0.0 , 0.5 ) , float4 ( 0.0 , - 0.5 , 0.0 , 0.5 ) , #line 598 float4 ( 0.0 , 0.0 , 0.5 , 0.5 ) , float4 ( 0.0 , 0.0 , 0.0 , 1.0 ) ) ; #line 613 #line 635 #line 642 #line 53 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" struct Opaque_vs_IN { #line 59 float3 position : POSITION ; #line 64 float2 uv : TEXCOORD0 ; } ; struct Opaque_vs_OUT { float4 position : SV_POSITION ; #line 74 float2 uv : TEXCOORD0 ; } ; #line 85 void Opaque_vs_main ( Opaque_vs_IN input , out Opaque_vs_OUT output ) { output . position = float4 ( input . position . x , - input . position . y , input . position . z , 1 ) ; #line 91 output . uv = input . uv ; } #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #line 642 #line 107 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" #line 116 struct Opaque_fs_v2f { float4 position : SV_POSITION ; float2 uv : TEXCOORD0 ; } ; struct Opaque_fs_f2f { float4 color : SV_TARGET0 ; } ; float4 pixelSize ; Texture2D < float4 > tex ; #line 138 void Opaque_fs_main ( Opaque_fs_v2f Opaque_fs_IN , out Opaque_fs_f2f Opaque_fs_OUT ) { const float2 kOffsets [ 9 ] = { float2 ( 0.0 , 0.0 ) , float2 ( 1.0 , 0.0 ) , float2 ( - 1.0 , 0.0 ) , float2 ( 0.0 , 1.0 ) , float2 ( 0.0 , - 1.0 ) , float2 ( 1.0 , 1.0 ) , float2 ( - 1.0 , 1.0 ) , float2 ( - 1.0 , - 1.0 ) , float2 ( 1.0 , - 1.0 ) } ; Opaque_fs_OUT . color . a = 0 ; for ( int i = 0 ; i < 9 ; i ++ ) { float2 uv = Opaque_fs_IN . uv + kOffsets [ i ] * pixelSize . xy ; Opaque_fs_OUT . color . a = max ( Opaque_fs_OUT . color . a , tex . Sample ( LinearClampSampler , uv ) . a ) ; } } technique11 Opaque { pass pass0 { SetVertexShader ( CompileShader ( vs_5_0 , Opaque_vs_main ( ) ) ) ; SetPixelShader ( CompileShader ( ps_5_0 , Opaque_fs_main ( ) ) ) ; SetBlendState ( NoBlend_BlendState , float4 ( 0.0f , 0.0f , 0.0f , 0.0f ) , 0xFFFFFFFF ) ; SetDepthStencilState ( NoDepthTest_NoDepthWrite_DepthState , 0 ) ; SetRasterizerState ( NoCull_RasterizerState ) ; } } #line 189 }D:\Dev\TGC\Journey\head\Journey\shaderd:\dev\tgc\journey\head\journey\shader#line 1 "D:\\Dev\\TGC\\Journey\\head\\Journey\\Data\\Shaders\\S_Resample_vs__NearDofBlur_fs__0.fx" #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" #line 4 BlendState ourBlendState { BlendEnable [ 0 ] = FALSE ; BlendEnable [ 1 ] = FALSE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBle0^)(0I()B< G GMicrosoft (R) HLSL Shader Compiler 10.1^=hlslFlags0x4005hlslTargetvs_5_0hlslEntryOpaque_vs_mainhlslDefines /DPHYRE_D3DFX=16HXX @Opaque_vs_main.> inputP@XP@XP@XP @XP@X.> outputP@XP@XP@XP@XP@XP @X 0h<ȑ e3C @X@XXXXXlXlX\\]]m9Nmkmk 18   ((0@ float3@float2& position  uv"Opaque_vs_IN@float4& position uv"Opaque_vs_OUT  18 ; #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #line 8 #line 16 #line 20 #line 135 #line 140 #line 147 BlendState NoBlend_BlendState { BlendEnable [ 0 ] = FALSE ; } ; BlendState Alpha_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = Src_Alpha ; DestBlendAlpha [ 0 ] = Inv_Src_Alpha ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; BlendState Additive_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = Src_Alpha ; DestBlend [ 0 ] = ONE ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = Src_Alpha ; DestBlendAlpha [ 0 ] = ONE ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; #line 180 BlendState ParticleBlended_BlendState { BlendEnable [ 0 ] = TRUE ; SrcBlend [ 0 ] = ONE ; DestBlend [ 0 ] = Inv_Src_Alpha ; BlendOp [ 0 ] = ADD ; SrcBlendAlpha [ 0 ] = ONE ; DestBlendAlpha [ 0 ] = Inv_Src_Alpha ; BlendOpAlpha [ 0 ] = ADD ; BlendEnable [ 1 ] = FALSE ; } ; DepthStencilState NoDepthTest_NoDepthWrite_DepthState { DepthEnable = FALSE ; DepthWriteMask = Zero ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState NoDepthTest_DepthWrite_DepthState { DepthEnable = FALSE ; DepthWriteMask = All ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState DepthTest_NoDepthWrite_DepthState { DepthEnable = TRUE ; DepthWriteMask = Zero ; DepthFunc = Less ; StencilEnable = FALSE ; } ; DepthStencilState DepthTest_DepthWrite_DepthState { DepthEnable = TRUE ; DepthWriteMask = All ; DepthFunc = Less ; StencilEnable = FALSE ; } ; RasterizerState NoCull_RasterizerState { CullMode = None ; } ; RasterizerState BackFaceCull_RasterizerState { CullMode = Back ; FrontCounterClockwise = TRUE ; } ; RasterizerState FrontFaceCull_RasterizerState { CullMode = Front ; FrontCounterClockwise = TRUE ; } ; #line 243 #line 246 #line 264 #line 269 sampler PointClampSampler : register ( s8 ) { Filter = Min_Mag_Mip_Point ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; } ; sampler LinearClampSampler : register ( s9 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; } ; sampler LinearWrapTSampler : register ( s10 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Clamp ; AddressV = Wrap ; AddressW = Clamp ; } ; sampler LinearWrapSampler : register ( s11 ) { Filter = Min_Mag_Mip_Linear ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; } ; sampler PointWrapSampler : register ( s12 ) { Filter = Min_Mag_Mip_Point ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; } ; sampler AnisoClampSampler : register ( s13 ) { Filter = ANISOTROPIC ; AddressU = Clamp ; AddressV = Clamp ; AddressW = Clamp ; MaxAnisotropy = 16 ; } ; sampler LinearWrapAnisoSampler : register ( s14 ) { Filter = ANISOTROPIC ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; MaxAnisotropy = 16 ; } ; sampler PointWrapAnisoSampler : register ( s15 ) { Filter = Min_Mag_Point_Mip_Linear ; AddressU = Wrap ; AddressV = Wrap ; AddressW = Wrap ; MaxAnisotropy = 16 ; } ; static const float kSRGB = 2.2f ; #line 358 #line 373 #line 408 #line 427 #line 435 #line 498 #line 516 #line 521 float cameraNearTimesFar ; float cameraFarMinusNear ; float4 cameraNearFar ; #line 527 float ConvertDepth ( float depth ) { #line 532 float viewSpaceZ = - ( cameraNearTimesFar / ( depth * cameraFarMinusNear - cameraNearFar . y ) ) ; return viewSpaceZ ; } #line 587 #line 592 static const float4x4 SCALE_BIAS = float4x4 ( float4 ( 0.5 , 0.0 , 0.0 , 0.5 ) , float4 ( 0.0 , - 0.5 , 0.0 , 0.5 ) , #line 598 float4 ( 0.0 , 0.0 , 0.5 , 0.5 ) , float4 ( 0.0 , 0.0 , 0.0 , 1.0 ) ) ; #line 613 #line 635 #line 642 #line 53 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" struct Opaque_vs_IN { #line 59 float3 position : POSITION ; #line 64 float2 uv : TEXCOORD0 ; } ; struct Opaque_vs_OUT { float4 position : SV_POSITION ; #line 74 float2 uv : TEXCOORD0 ; } ; #line 85 void Opaque_vs_main ( Opaque_vs_IN input , out Opaque_vs_OUT output ) { output . position = float4 ( input . position . x , - input . position . y , input . position . z , 1 ) ; #line 91 output . uv = input . uv ; } #line 0 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh" #line 642 #line 107 "D:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fx" #line 116 struct Opaque_fs_v2f { float4 position : SV_POSITION ; float2 uv : TEXCOORD0 ; } ; struct Opaque_fs_f2f { float4 color : SV_TARGET0 ; } ; float4 pixelSize ; Texture2D < float4 > tex ; #line 138 void Opaque_fs_main ( Opaque_fs_v2f Opaque_fs_IN , out Opaque_fs_f2f Opaque_fs_OUT ) { const float2 kOffsets [ 9 ] = { float2 ( 0.0 , 0.0 ) , float2 ( 1.0 , 0.0 ) , float2 ( - 1.0 , 0.0 ) , float2 ( 0.0 , 1.0 ) , float2 ( 0.0 , - 1.0 ) , float2 ( 1.0 , 1.0 ) , float2 ( - 1.0 , 1.0 ) , float2 ( - 1.0 , - 1.0 ) , float2 ( 1.0 , - 1.0 ) } ; Opaque_fs_OUT . color . a = 0 ; for ( int i = 0 ; i < 9 ; i ++ ) { float2 uv = Opaque_fs_IN . uv + kOffsets [ i ] * pixelSize . xy ; Opaque_fs_OUT . color . a = max ( Opaque_fs_OUT . color . a , tex . Sample ( LinearClampSampler , uv ) . a ) ; } } technique11 Opaque { pass pass0 { SetVertexShader ( CompileShader ( vs_5_0 , Opaque_vs_main ( ) ) ) ; SetPixelShader ( CompileShader ( ps_5_0 , Opaque_fs_main ( ) ) ) ; SetBlendState ( NoBlend_BlendState , float4 ( 0.0f , 0.0f , 0.0f , 0.0f ) , 0xFFFFFFFF ) ; SetDepthStencilState ( NoDepthTest_NoDepthWrite_DepthState , 0 ) ; SetRasterizerState ( NoCull_RasterizerState ) ; } } #line 189 D:\\Dev\\TGC\\Journey\\head\\Journey\\Data\\Shaders\\S_Resample_vs__NearDofBlur_fs__0.fxD:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fxD:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory.sh (PC)D3DSHDR ` /%Opaque_vs_main / /sh  ` LOpaque_vs_mainnonew 1 ?\T ,$ ` LOpaque_vs_mainnone-. `'D:\Dev\TGC\Journey\head\Journey\shaderD:\\Dev\\TGC\\Journey\\head\\Journey\\Data\\Shaders\\S_Resample_vs__NearDofBlur_fs__0.fxD:/Dev/TGC/Journey/head/Journey/Data/Shaders/S_Resample_vs__NearDofBlur_fs__0.fxD:/Dev/TGC/Journey/head/Journey/Data/Shaders/Migratory..1c^*˞7C !T/LinkInfo/names/src/headerblock/src/files/d:\dev\tgc\journey\head\journey\shader" Q3 D38I00( , 210 !"#$%&'()* +,-/.3POSITIONTEXCOORDPEffectVariantPMaterialOpaqueVertexST   ' 555555h5P586 1XhX1PXZPAP XXXP1 XXXXXXXXHP!PAP! PaXX PQ P P P  P  hPha<AdP>&v A