Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[glsl] mova not implemented #27

Open
kg opened this issue Jun 7, 2020 · 2 comments
Open

[glsl] mova not implemented #27

kg opened this issue Jun 7, 2020 · 2 comments
Labels
bug Something isn't working

Comments

@kg
Copy link
Contributor

kg commented Jun 7, 2020

In some specific cases, fxc will emit the mova instruction, which moves a float or int value into the a0 address register (which is an integer).

So the source assembly would look like:

dcl_blendindices v6
mova a0.x, v6.x

However, right now the generated GLSL looks like this:

vec4 vs_r1;
ivec4 vs_a0;

// error C7011: implicit cast from "float" to "int"
vs_a0.x = vs_r1.z;

Should be an easy fix, just ensure that we do an explicit cast when handling mova.

@flibitijibibo
Copy link
Collaborator

This is where the important stuff starts:

https://github.com/FNA-XNA/MojoShader/blob/upstream/profiles/mojoshader_profile_glsl.c#L258

We also need the shader binary in question.

@flibitijibibo
Copy link
Collaborator

@flibitijibibo flibitijibibo changed the title mova not implemented [glsl] mova not implemented Jul 13, 2021
@flibitijibibo flibitijibibo added the bug Something isn't working label Jul 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants