Skip to content
Snippets Groups Projects
Commit c47ee880 authored by Emma Anholt's avatar Emma Anholt Committed by Keith Packard
Browse files

glamor: Don't try to set up core fonts textures when we won't use them.


This happens to avoid GL errors on hardware without
EXT_texture_integer (which implies < GLSL 130, and thus glamor_text.c
programs not compiling anyway).

Signed-off-by: default avatarEric Anholt <eric@anholt.net>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarKeith Packard <keithp@keithp.com>
parent d09c9ddb
No related branches found
No related tags found
No related merge requests found
......@@ -46,6 +46,8 @@ glamor_font_get(ScreenPtr screen, FontPtr font)
CharInfoPtr glyph;
unsigned long count;
if (glamor_priv->glsl_version < 130)
return NULL;
privates = FontGetPrivate(font, glamor_font_private_index);
if (!privates) {
......@@ -167,6 +169,11 @@ glamor_unrealize_font(ScreenPtr screen, FontPtr font)
Bool
glamor_font_init(ScreenPtr screen)
{
glamor_screen_private *glamor_priv = glamor_get_screen_private(screen);
if (glamor_priv->glsl_version < 130)
return TRUE;
if (glamor_font_generation != serverGeneration) {
glamor_font_private_index = AllocateFontPrivateIndex();
if (glamor_font_private_index == -1)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment