首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >E/EGL_EGL_BAD_MATCH: tid 2633: eglSurfaceAttrib(1165):error 0x3009 (EGL_BAD_MATCH)

E/EGL_EGL_BAD_MATCH: tid 2633: eglSurfaceAttrib(1165):error 0x3009 (EGL_BAD_MATCH)
EN

Stack Overflow用户
提问于 2016-12-18 11:27:03
回答 1查看 9.6K关注 0票数 2

嗨,我是android编程的哑巴,然后我在构建应用程序上遇到了一些问题。我试着用这个xml代码构建应用程序:

代码语言:javascript
复制
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:id="@+id/activity_main"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:paddingBottom="@dimen/activity_vertical_margin"
    android:paddingLeft="@dimen/activity_horizontal_margin"
    android:paddingRight="@dimen/activity_horizontal_margin"
    android:paddingTop="@dimen/activity_vertical_margin"
    tools:context="com.ebookfrenzy.androidsample.MainActivity">

    <EditText
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:inputType="textPersonName"
        android:text="@string/Namestring"
        android:ems="10"
        android:layout_above="@+id/button"
        android:layout_centerHorizontal="true"
        android:layout_marginBottom="28dp"
        android:id="@+id/editText" />

    <Button
        android:text="@string/PressMeString"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:id="@+id/button"
        android:layout_centerVertical="true"
        android:layout_centerHorizontal="true"
        android:textAllCaps="false" />
</RelativeLayout>

然后,我在ADV机器中得到了一个错误:

代码语言:javascript
复制
$ adb shell am start -n "com.ebookfrenzy.androidsample/com.ebookfrenzy.androidsample.AndroidSampleActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER
Connected to process 2542 on device emulator-5554
I/art: Not late-enabling -Xcheck:jni (already on)
W/System: ClassLoader referenced unknown path: /data/app/com.ebookfrenzy.androidsample-1/lib/x86_64
I/InstantRun: Instant Run Runtime started. Android package is com.ebookfrenzy.androidsample, real application class is null.
W/System: ClassLoader referenced unknown path: /data/app/com.ebookfrenzy.androidsample-1/lib/x86_64
W/art: Before Android 4.1, method android.graphics.PorterDuffColorFilter android.support.graphics.drawable.VectorDrawableCompat.updateTintFilter(android.graphics.PorterDuffColorFilter, android.content.res.ColorStateList, android.graphics.PorterDuff$Mode) would have incorrectly overridden the package-private method in android.graphics.drawable.Drawable
D/OpenGLRenderer: Use EGL_SWAP_BEHAVIOR_PRESERVED: true

                  [ 12-18 20:03:53.363  2542: 2542 D/         ]
                  HostConnection::get() New Host Connection established 0x7f710991c140, tid 2542


                  [ 12-18 20:03:53.377  2542: 2542 W/         ]
                  Process pipe failed

                  [ 12-18 20:03:53.502  2542: 2587 D/         ]
                  HostConnection::get() New Host Connection established 0x7f710991b3c0, tid 2587
I/OpenGLRenderer: Initialized EGL, version 1.4
E/EGL_emulation: tid 2587: eglSurfaceAttrib(1165): error 0x3009 (EGL_BAD_MATCH)
W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0x7f710139e400, error=EGL_BAD_MATCH

它中的一些答案是“尝试将Randering设置为"Harware Randering",但是它不能工作并且接收相同的错误消息。我如何修复它?

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2017-01-21 01:28:25

为什么会发生这种事?我发现了以下情况:

如果属性为EGL_SWAP_BEHAVIOR,值为EGL_BUFFER_PRESERVED,则生成EGL_BUFFER_PRESERVED,用于创建曲面的EGLConfig的EGL_SURFACE_TYPE属性不包含EGL_SWAP_BEHAVIOR_PRESERVED_BIT。

参考资料:eglSurfaceAttrib,khronos集团是一个非盈利组织,提供标准的OpenGL接口。

你怎么解决这个问题?在Android仿真程序中,您可以使用内置(硬件)图形卡。我希望能帮上忙。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/41207879

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档