mirror of
https://github.com/elwrcl/intel-hard-graphics.git
synced 2026-10-31 10:58:03 +03:00
Nine Mesa 25.2'de silindi. Bu commit onu 26.2 agacina geri getiriyor:
src/gallium/frontends/nine, src/gallium/targets/d3dadapter9, D3D9 ve
d3dadapter basliklari, meson entegrasyonu ve driconf secenekleri.
Silinmesinden sonra gallium'da degisen ve uyum gerektiren yerler:
- mesa_shader_stage, enum pipe_shader_type'in yerini aldi
- pipe_surface de-pointerize edildi, create_surface kalkti
- u_upload_data/alloc artik referans vermiyor; _ref varyantlarina gecildi
- threaded_context kullanici sabit tamponlarini yuklemiyor (MR 36715),
tc_set_constant_buffer'da assert(!cb->user_buffer) var. SWVP ve
fixed-function yollari icin nine_upload_constant_buffer() eklendi.
- driParseConfigFiles struct API'sine gecti
Ayrica D3D9'un ugradigi ama GL frontend'inin hic gecmedigi uc yolda
surucu hatasi cikti; ucu de burada:
crocus_query.c PIPE_QUERY_GPU_FINISHED ele alinmiyordu
crocus_clear.c clear_render_target gelen pipe_surface'i crocus_surface'e
cast edip ->view okuyordu; Nine kendi surface'ini
uretiyor, format crocus_format_for_usage ile yeniden
turetiliyor
tgsi_to_nir.c TXD'de ddx/ddy bilesen sayisi kirpilmiyordu
Gercek donanimda dogrulandi (8086:0166, crocus, wine 11.0 +
wine-nine-standalone): Max Payne 2, The Witcher EE, Fallout New Vegas,
Warband, L4D1, PAYDAY: The Heist calisiyor.
Co-Authored-By: Claude Opus 5 <[email protected]>
101 lines
4.3 KiB
C
101 lines
4.3 KiB
C
/*
|
|
* Copyright 2011 Joakim Sindholt <[email protected]>
|
|
* SPDX-License-Identifier: MIT
|
|
*/
|
|
|
|
#include "nine_debug.h"
|
|
|
|
#include <ctype.h>
|
|
#include "c11/threads.h"
|
|
|
|
static const struct debug_named_value nine_debug_flags[] = {
|
|
{ "unknown", DBG_UNKNOWN, "IUnknown implementation." },
|
|
{ "adapter", DBG_ADAPTER, "ID3D9Adapter implementation." },
|
|
{ "overlay", DBG_OVERLAYEXTENSION, "IDirect3D9ExOverlayExtension implementation." },
|
|
{ "auth", DBG_AUTHENTICATEDCHANNEL, "IDirect3DAuthenticatedChannel9 implementation." },
|
|
{ "basetex", DBG_BASETEXTURE, "IDirect3DBaseTexture9 implementation." },
|
|
{ "crypto", DBG_CRYPTOSESSION, "IDirect3DCryptoSession9 implementation." },
|
|
{ "cubetex", DBG_CUBETEXTURE, "IDirect3DCubeTexture9 implementation." },
|
|
{ "device", DBG_DEVICE, "IDirect3DDevice9(Ex) implementation." },
|
|
{ "video", DBG_DEVICEVIDEO, "IDirect3DDeviceVideo9 implementation." },
|
|
{ "ibuf", DBG_INDEXBUFFER, "IDirect3DIndexBuffer9 implementation." },
|
|
{ "ps", DBG_PIXELSHADER, "IDirect3DPixelShader9 implementation." },
|
|
{ "query", DBG_QUERY, "IDirect3DQuery9 implementation." },
|
|
{ "res", DBG_RESOURCE, "IDirect3DResource9 implementation." },
|
|
{ "state", DBG_STATEBLOCK, "IDirect3DStateBlock9 implementation." },
|
|
{ "surf", DBG_SURFACE, "IDirect3DSurface9 implementation." },
|
|
{ "swap", DBG_SWAPCHAIN, "IDirect3DSwapChain9(Ex) implementation." },
|
|
{ "tex", DBG_TEXTURE, "IDirect3DTexture9 implementation." },
|
|
{ "vbuf", DBG_VERTEXBUFFER, "IDirect3DVertexBuffer9 implementation." },
|
|
{ "vdecl", DBG_VERTEXDECLARATION, "IDirect3DVertexDeclaration9 implementation." },
|
|
{ "vs", DBG_VERTEXSHADER, "IDirect3DVertexShader9 implementation." },
|
|
{ "3dsurf", DBG_VOLUME, "IDirect3DVolume9 implementation." },
|
|
{ "3dtex", DBG_VOLUMETEXTURE, "IDirect3DVolumeTexture9 implementation." },
|
|
{ "shader", DBG_SHADER, "Shader token stream translator." },
|
|
{ "ff", DBG_FF, "Fixed function emulation." },
|
|
{ "user", DBG_USER, "User errors, both fixable and unfixable." },
|
|
{ "error", DBG_ERROR, "Driver errors, always visible." },
|
|
{ "warn", DBG_WARN, "Driver warnings, always visible in debug builds." },
|
|
{ "tid", DBG_TID, "Display thread-ids." },
|
|
DEBUG_NAMED_VALUE_END
|
|
};
|
|
|
|
void
|
|
_nine_debug_printf( unsigned long flag,
|
|
const char *func,
|
|
const char *fmt,
|
|
... )
|
|
{
|
|
static bool first = true;
|
|
static unsigned long dbg_flags = DBG_ERROR | DBG_WARN;
|
|
unsigned long tid = 0;
|
|
|
|
if (first) {
|
|
first = false;
|
|
dbg_flags |= debug_get_flags_option("NINE_DEBUG", nine_debug_flags, 0);
|
|
}
|
|
|
|
#if defined(HAVE_PTHREAD)
|
|
if (dbg_flags & DBG_TID)
|
|
tid = (unsigned long)pthread_self();
|
|
#endif
|
|
|
|
if (dbg_flags & flag) {
|
|
const char *f = func ? strrchr(func, '_') : NULL;
|
|
va_list ap;
|
|
/* inside a class this will print nine:tid:classinlowercase:func: while
|
|
* outside a class (rarely used) it will just print nine:tid:func
|
|
* the reason for lower case is simply to match the filenames, as it
|
|
* will also strip off the "Nine" */
|
|
if (f && strncmp(func, "Nine", 4) == 0) {
|
|
char klass[96]; /* no class name is this long */
|
|
char *ptr = klass;
|
|
for (func += 4; func != f; ++func) { *ptr++ = tolower(*func); }
|
|
*ptr = '\0';
|
|
if (tid)
|
|
_debug_printf("nine:0x%08lx:%s:%s: ", tid, klass, ++f);
|
|
else
|
|
_debug_printf("nine:%s:%s: ", klass, ++f);
|
|
} else if (func) {
|
|
if (tid)
|
|
_debug_printf("nine:0x%08lx:%s ", tid, func);
|
|
else
|
|
_debug_printf("nine:%s ", func);
|
|
}
|
|
|
|
va_start(ap, fmt);
|
|
_debug_vprintf(fmt, ap);
|
|
va_end(ap);
|
|
}
|
|
}
|
|
|
|
void
|
|
_nine_stub( const char *file,
|
|
const char *func,
|
|
unsigned line )
|
|
{
|
|
const char *r = strrchr(file, '/');
|
|
if (r == NULL) { r = strrchr(file, '\\'); }
|
|
_debug_printf("nine:%s:%d: %s STUB!\n", r ? ++r : file, line, func);
|
|
}
|