I'm working with legacy code that is using vs_2_0 and ps_2_0 assembly shader code in an effect file. I'm looking to add some pixel shaders to work with existing the vertex shader, but would like to use HLSL. Is it possible to add an HLSL pixel shader in the same technique with the asm vertex shader? If so, how do I access the vertex shader output (oT0, oT1) in my HLSL pixel shader? I'm new to shaders in general, so the simpler the better.
Mix asm vertex shader with HLSL pixel shader in effect
501 Views Asked by Matthew Dickerson At
1
There are 1 best solutions below
Related Questions in HLSL
- Decal renderer does not discard pixels properly
- gl_DrawID equivalent for Directx12 ExecuteIndirect HLSL
- Missing HLSL Debug Symbols with D3Dcompile in Visual Studio
- C++ DirectX compress 3D texture into 2D texture
- How do I change the way my brace completion is handled in Visual Studio 2022 for Unity when coding in HLSL?
- How to get screen UVs in the vert stage of a unity shader?
- Delphi FMX: How to write a custom shader filter?
- Ternary operator with SamplerStates
- Implementing the Phong reflection model in a compute shader - unexpected response to change of spectral and diffuse coefficients
- How can I safely alter a texture from multiple threads? (seems like there is no `InterlockedAdd`)
- Compute Shader call breaks following Blit call in build, but not in editor
- Point light shadows work wrong, how can I debug it?
- Simultaneous access to the same pixel in a ray generation shader - is it safe?
- D3D12: Can we really not have a 1-dimensional buffer/texture of size > 25000?
- How can I fix the normals in this instanced lighting example? (Monogame/XNA)
Related Questions in VERTEX-SHADER
- WebGL Position vertex inside vertex shader?
- QOpenGLWidget with Qpainter: OpenGL drawing only visible after first paintGL call
- Why is outline calculation 1px less than it should be?
- Calculate TBN Matrix after modify position of vertex in vertex shader?
- Rotate UVs in Vertex Shader without distorting texture
- Texture reflection on adjacent geometry surface
- Primitive do not show up on screen
- Efficient way to draw a nice line using the Metal API
- I'm trying to create a displacement map transition between three images using ThreeJs and I'm stuck
- How to Implement ShaderToy in Threejs ShaderMaterial?
- How to use shader from ShaderToy in Three.js?
- THREEjs change shadows after vertex shader
- Godot vertex shader to bend a mesh along a path (similar to the Blender's "Curve" modifier)
- d3d12: when adding a constant buffer, the Output structure changes
- same JS code in 2 diiferent WebGL applications, works in 1 but fails in other: problem with vertexAttribute?
Related Questions in PIXEL-SHADER
- Is the render target view the only way to output data from pixel shader in DirectX?
- D3D Texture convert Format
- Why does this HLSL pixel shader not compile?
- Variable Width Outline Effect Around a Texture in 2D
- Use of "ScreenTC" and "TC_Window" in fragment shaders
- Red colored point light not projecting correctly [D3D11]
- problem with Creating textures in DirectX 12
- Discarding pixels in ps_2_0?
- Textures do not get accessed properly in pixel shader (DirectX11)
- Normal map overrides smooth edges in DirectX 11
- Converting pixelshader asm to HLSL
- Mix asm vertex shader with HLSL pixel shader in effect
- How to correct this HLSL pixel shader to round corners of a quad?
- How do pixel values behave in DirectX 11 HLSL shaders?
- Having trouble converting a d3d9 pixelshader to d3d11
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
If you're using dx9 effect framework, then for the technique setup, you can
As shown in MSDN
And for matching vs outputs, check out DirectX 9 hlsl Semetics, and ps_2_0 input registers, what's available to ps_2_0 is
TEXCOORD#COLOR#which will compile tot#andv#respectively.For example:
compiles to
I would also recommend using hlsl offline compiler (fxc) to list assembly output and check for yourself if things has lined up. or considered using the handy online shader compiler by Tim Jones