[Openchrome-users] Max Texture Size
Thomas Hellström
thomas
Sun May 14 02:45:01 PDT 2006
Hi, Boris.
I'll have a look at the patch next week. I have an important delivery at
the beginning of the week.
BTW, the names driconf uses should be controlled by the driver so it's
probably not a driconf bug. Probably somewhere in the setup the
Unichrome driver still calls itself "via".
/Thomas
Boris Du?ek wrote:
>Hi Thomas,
>
>I have completed a patch, all getenv's have their driQueryOptionb counterparts
>now. I have tested the patch only by compiling and viewing the options present
>in driconf. The patch includes the previous patch I sent you with
>allow_large_textures.
>
>Btw. driconf has a bug - it uses name "unichrome" for the device, whereas
>"via" is correct, so the config file resulting from it has no effect unless
>one changes the device name to the correct value. I will report that to xorg
>mailing list.
>
>Questions I have:
>
>should I completely remove the env. variable settings below, or leave it as it
>is in the patch, that is a tandem of env. variable and drirc option decides
>and env. variable has higher priotiry?
>
>And now questions specifically for each one:
>
>On Thursday 11 May 2006 22:21, you wrote:
>
>
>>via_context.c: if (getenv("ALTERNATE_SCREEN"))
>>
>>
>I don't know what it does - could you please provide a description so that
>driconf users get an idea (and me too :)
>
>
>
>>via_context.c: if (getenv("VIA_DEBUG"))
>>via_context.c: VIA_DEBUG = driParseDebugString( getenv( "VIA_DEBUG"
>>
>>
>this would benefit from xmlconfig.c extended to handle flag-type variables; if
>you think it is a good idea, I will try to implement it in future if/when I
>have more time;
>
>
>
>>), via_context.c: if (getenv("VIA_NO_RAST"))
>>
>>
>that was the easiest option :)
>
>
>
>>via_context.c: vmesa->vblank_flags = (getenv("VIA_VSYNC") ?
>>
>>
>seen some comments about non-functionality of drirc configuration using
>driGetDefaultVBlankFlags, I too don't understand why that would not work
>(maybe the comment is outdated), will try to test it
>
>
>
>>via_context.c: if (getenv("VIA_PAGEFLIP"))
>>
>>
>I need a description for it too; I added the option to
>common/xmlpool/t_options.h since other drivers also use PageFlip setting (but
>none queries neither drirc nor env. variable) and may be interested in using
>it too
>
>
>
>>via_tex.c: if (getenv("VIA_NO_SSE"))
>>
>>
>What gets resolved with this is toggling the apparently buggy sse_memcpy. Now
>there is "sse_memcpy" option set by default to false. The new thing is that
>one can enable it in drirc with the full "per application settings"
>flexibility. I have reenabled the via_sse_memcpy code, so if one sets
><option name="sse_memcpy" value="true" />, it will have a real effect.
>
>Finally DRI_CONF_FTHROTTLE_MODE is not used anywhere but is declared in
>__driConfigOptions - is it to be used somewhere, or did it accidentally
>result from copying that code from radeon driver, as possibly suggested by the
>comment before the declaration of __driConfigOptions?
>
>Regards,
>Boris
>
>
>
>>These should ideally also be moved to driconf option handling, which is
>>only a matter of finishing what others have started.
>>
>>
>
>
>
>>/Thmas
>>
>>
>>------------------------------------------------------------------------
>>
>>Index: common/xmlpool/t_options.h
>>===================================================================
>>RCS file: /cvs/mesa/Mesa/src/mesa/drivers/dri/common/xmlpool/t_options.h,v
>>retrieving revision 1.2
>>diff -r1.2 t_options.h
>>219a220,224
>>
>>
>>>#define DRI_CONF_PAGEFLIP(def) \
>>>DRI_CONF_OPT_BEGIN(pageflip,bool,def) \
>>> DRI_CONF_DESC_BEGIN(en,gettext("Enable page flipping")) \
>>>DRI_CONF_OPT_END
>>>
>>>
>>>
>>Index: unichrome/via_context.c
>>===================================================================
>>RCS file: /cvs/mesa/Mesa/src/mesa/drivers/dri/unichrome/via_context.c,v
>>retrieving revision 1.60
>>diff -r1.60 via_context.c
>>276c276,277
>>< if (getenv("ALTERNATE_SCREEN"))
>>---
>>
>>
>>> if (getenv("ALTERNATE_SCREEN") ||
>>> driQueryOptionb (&vmesa->optionCache, "alternate_screen"))
>>>
>>>
>>538c539
>>< viaInitTextureFuncs(&functions);
>>---
>>
>>
>>> viaInitTextureFuncs(&vmesa->optionCache, &functions);
>>>
>>>
>>557a559
>>
>>
>>559c561,566
>>< ctx->Const.MaxTextureLevels = 10;
>>---
>>
>>
>>> if (driQueryOptioni(&vmesa->optionCache, "allow_large_textures"))
>>> ctx->Const.MaxTextureLevels = 11;
>>> else
>>> ctx->Const.MaxTextureLevels = 10;
>>>
>>>
>>>
>>647a655
>>
>>
>>>
>>>
>>>
>>658c666,667
>>< if (getenv("VIA_NO_RAST"))
>>---
>>
>>
>>> if (getenv("VIA_NO_RAST") ||
>>> driQueryOptionb (&vmesa->optionCache, "no_rast"))
>>>
>>>
>>672c681,682
>>< if (getenv("VIA_PAGEFLIP"))
>>---
>>
>>
>>> if (getenv("VIA_PAGEFLIP") ||
>>> driQueryOptionb (&vmesa->optionCache, "pageflip"))
>>>
>>>
>>728a739,740
>>
>>
>>> driDestroyOptionCache (&vmesa->optionCache);
>>>
>>>
>>>
>>Index: unichrome/via_screen.c
>>===================================================================
>>RCS file: /cvs/mesa/Mesa/src/mesa/drivers/dri/unichrome/via_screen.c,v
>>retrieving revision 1.32
>>diff -r1.32 via_screen.c
>>49,50d48
>>< /* Radeon configuration
>>< */
>>52a51,60
>>
>>
>>>#define DRI_CONF_ALTERNATE_SCREEN(def) \
>>>DRI_CONF_OPT_BEGIN(alternate_screen,bool,def) \
>>> DRI_CONF_DESC(en,"Enable alternate screen") \
>>>DRI_CONF_OPT_END
>>>
>>>#define DRI_CONF_SSE_MEMCPY(def) \
>>>DRI_CONF_OPT_BEGIN(sse_memcpy,bool,def) \
>>> DRI_CONF_DESC(en,"Enable SSE memcpy") \
>>>DRI_CONF_OPT_END
>>>
>>>
>>>
>>57a66,71
>>
>>
>>> DRI_CONF_ALTERNATE_SCREEN(false)
>>> DRI_CONF_PAGEFLIP(false)
>>> DRI_CONF_SSE_MEMCPY(false)
>>> DRI_CONF_SECTION_END
>>> DRI_CONF_SECTION_QUALITY
>>> DRI_CONF_ALLOW_LARGE_TEXTURES(0)
>>>
>>>
>>63c77
>>< static const GLuint __driNConfigOptions = 3;
>>---
>>
>>
>>>static const GLuint __driNConfigOptions = 7;
>>>
>>>
>>208a223,224
>>
>>
>>> driDestroyOptionInfo (&viaScreen->optionCache);
>>>
>>>
>>>
>>Index: unichrome/via_tex.c
>>===================================================================
>>RCS file: /cvs/mesa/Mesa/src/mesa/drivers/dri/unichrome/via_tex.c,v
>>retrieving revision 1.14
>>diff -r1.14 via_tex.c
>>514a515,522
>>
>>
>>> /* The hardware only supports 10 mipmap levels. Ignore higher levels.
>>> */
>>>
>>> if ((numLevels > 10) && (ctx->Const.MaxTextureLevels > 10)) {
>>> lastLevel -= numLevels - 10;
>>> numLevels = 10;
>>> }
>>>
>>>
>>>
>>947c955,956
>>< void viaInitTextureFuncs(struct dd_function_table * functions)
>>---
>>
>>
>>>void viaInitTextureFuncs(driOptionCache * optionCache,
>>> struct dd_function_table * functions)
>>>
>>>
>>960c969
>>< #if 0 && defined( USE_SSE_ASM )
>>---
>>
>>
>>>#if defined( USE_SSE_ASM )
>>>
>>>
>>962,963c971
>>< * XXX this code is disabled for now because the via_sse_memcpy()
>>< * routine causes segfaults with flightgear.
>>---
>>
>>
>>> * the via_sse_memcpy() routine causes segfaults with flightgear.
>>>
>>>
>>965d972
>>< * Note that this function is currently disabled in via_tris.c too.
>>967c974,975
>>< if (getenv("VIA_NO_SSE"))
>>---
>>
>>
>>> if (getenv("VIA_NO_SSE") ||
>>> !driQueryOptionb (optionCache, "sse_memcpy"))
>>>
>>>
>>979d986
>><
>>Index: unichrome/via_tex.h
>>===================================================================
>>RCS file: /cvs/mesa/Mesa/src/mesa/drivers/dri/unichrome/via_tex.h,v
>>retrieving revision 1.6
>>diff -r1.6 via_tex.h
>>29a30
>>
>>
>>>#include "xmlconfig.h"
>>>
>>>
>>34c35
>>< void viaInitTextureFuncs(struct dd_function_table * functions);
>>---
>>
>>
>>>void viaInitTextureFuncs(driOptionCache * optionCache, struct dd_function_table * functions);
>>>
>>>
>>Index: unichrome/via_tris.c
>>===================================================================
>>RCS file: /cvs/mesa/Mesa/src/mesa/drivers/dri/unichrome/via_tris.c,v
>>retrieving revision 1.37
>>diff -r1.37 via_tris.c
>>58c58
>>< #if 0
>>---
>>
>>
>>>#if defined( USE_SSE_ASM )
>>>
>>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://wiki.openchrome.org/pipermail/openchrome-users/attachments/20060514/71f297cd/attachment-0001.html
More information about the Openchrome-users
mailing list