| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
Fixes #22181. R200 requires this since DP4 is used in hw tnl mode.
R300 prefers it (should be faster due to no instruction dependencies), but
both methods should be correct (when sw tcl is used though, MUL/MAD might
be faster). Probably doesn't make much difference for R100 since vertex progs
are executed in software anyway, but let's just keep it the same there too.
|
|
|
|
| |
This lets ut2004 avoid hitting the elt warning.
|
|
|
|
|
|
|
| |
vap index offset is programmed to 0 by the kernel, it
would add work to kernel checker to allow userspace
programming of this so it's now disallowed with CS
on KMS.
|
|
|
|
| |
Tested with glean/texture_srgb and wine/d3d9 tests on RV535
|
|
|
|
| |
use the actual value set in the context
|
|
|
|
| |
If GL context had e.g. tex0, tex2 and fog the VAPOutputCntl1 returned 0x104 instead of 0x124 - that meaned we're sending only 8 texcoords (instead of 12) which ended up in GPU hang.
|
|
|
|
|
| |
We shouldn't use i variable for SWTCL_OVM_TEX because textures doesn't have to be enabled in "packed" order.
We could have tex1,tex3 and fog which would receive 7,9,8 OVM locations instead of 6,7,8.
|
| |
|
| |
|
|
|
|
| |
RS_COL_FMT field is part of RS_IP_* reg not RS_INST_*
|
|
|
|
|
|
|
|
|
| |
- when rewriting per component negate swizzle, first instruction should get not negated source
- KIL instruction ignores swizzles
TODO:
- tex instructions does not support saturation
- tex instructions cannot read from consant memory
|
|
|
|
|
|
| |
Sending from VAP more texture coordinates than RS expects results in GPU hang.
Fixes BumpSelfShadow from DirectX8 SDK.
|
|
|
|
|
|
| |
If the vertex program didn't write position attribute, the position invariant function would add necessary instructions, but the vertex position would be overwritten by artificial outputs insts added to satisfy fragment program requirements.
Fixes "whole screen is gray" problem for HW TCL path in sauerbraten when shaders are enabled, and whole slew of wine d3d9 tests.
|
| |
|
| |
|
|
|
|
| |
If the vertex program wrote secondary color without primary color, the secondary color output register index would be 0 which resulted in overwriting vertex position in some cases.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
vertices
When with memory manager we need to make sure the GPU won't try to access
beyond vertex buffer size, do so by enforcing that the maximun index is the
last vertex of the buffer.
|
|
|
|
| |
Fixes GPU hangs in software TCL path
|
|
|
|
| |
Signed-off-by: Maciej Cencora <[email protected]>
|
| |
|
|
|
|
|
|
|
| |
Also when index format is GL_UBYTE, convert it to GL_USHORT not GL_UINT.
Fix license header too.
Reported by: Nicolai Hähnle <[email protected]>
|
| |
|
|
|
|
| |
software TCL path
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Always allocate the vertex program input registers in the same order as the vertex attributes are passed in vertex arrays.
|
|
|
|
| |
Even if we don't pass all 4 color components to vertex shader unit, the vertex program can generate the missing components.
|
| |
|
| |
|
|
|
|
|
|
|
| |
The duplication of state data caused a crash due to double-free on destruction
of context, because a variable wasn't correctly null'ed out.
Signed-off-by: Nicolai Hähnle <[email protected]>
|
|
|
|
|
| |
This still need some work to actually report somethings reasonable
if no memory manager is available.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
- move vertex program related functions to r300_vertprog.c
- use _mesa_bitcount instead of self-made bit_count function
- remove duplicated field in r300_vertex_shader_fragment.body union
- rename r300_vertex_shader_fragment to r300_vertex_shader_hw_code
- rename r300_vertex_program field native to error
- remove unnecessary r300_vertex_shader_state structure
- remove unused r300_vertex_program and r300_vertex_program_cont fields
- remove disabled code
|
| |
|
|
|
|
|
| |
- remove unnecessary r300TranslateFragmentShader call from r300UpdateShaderStates (it is already called in r300UpdateShaders)
- remove unnecessary null ptr checks
|
| |
|
|
|
|
| |
Be consistent with function naming: use Setup/Emit names for functions that modify hardware state
|
| |
|
|
|
|
|
| |
Until now falling back to software rasterizer worked only for TCL enabled cards.
For non TCL cards we used to plug our rendering functions in r300InitSwtcl, and we had never restored original functions for software rasterizer.
|
| |
|
| |
|
|
|
|
|
|
|
| |
- move extensions init into seperate function
- move options handling into seperate function
- create new structure to hold options values
- use context->options.hw_tcl_enabled field instead of global hw_tcl_on and future_hw_tcl_on variables
|
| |
|
|
|
|
|
|
|
|
| |
In r300SetTexBuffer2(), if the passed in text glx_texture_format
is GLX_TEXTURE_FORMAT_RGB_EXT, then we should use an RGB-only
texture format, even if the DRI buffer has four channels.
https://bugs.freedesktop.org/show_bug.cgi?id=21609
|
|
|
|
|
|
|
|
| |
Remove an eigth-pixel offset of the viewport inherited from
R100 code. This seems not to be necessary and causes blurring
when sampling textures 1:1.
https://bugs.freedesktop.org/show_bug.cgi?id=20340
|
|
|
|
|
| |
This was broken with last merge see 62043b27575c378c027251316421e4699f461108
for explanations
|