小编Qbu*_*3kZ的帖子

与Eclipse崩溃的人行横道

我在本教程中添加了Crosswalk eclipse:ClickHere 我完成了教程中的所有操作并且没有错误,但是当我在手机上启动应用程序时,我有这样的:

02-19 13:37:08.147: E/AndroidRuntime(21108): FATAL EXCEPTION: main
02-19 13:37:08.147: E/AndroidRuntime(21108): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.crosswalktest/com.example.crosswalktest.MainActivity}: android.view.InflateException: Binary XML file line #1: Error inflating class org.xwalk.core.XWalkView
02-19 13:37:08.147: E/AndroidRuntime(21108):    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2092)
02-19 13:37:08.147: E/AndroidRuntime(21108):    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2117)
02-19 13:37:08.147: E/AndroidRuntime(21108):    at android.app.ActivityThread.access$700(ActivityThread.java:134)
02-19 13:37:08.147: E/AndroidRuntime(21108):    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1218)
02-19 13:37:08.147: E/AndroidRuntime(21108):    at android.os.Handler.dispatchMessage(Handler.java:99)
02-19 13:37:08.147: E/AndroidRuntime(21108):    at android.os.Looper.loop(Looper.java:137)
02-19 13:37:08.147: E/AndroidRuntime(21108):    at android.app.ActivityThread.main(ActivityThread.java:4867)
02-19 13:37:08.147: E/AndroidRuntime(21108):    at java.lang.reflect.Method.invokeNative(Native Method)
02-19 13:37:08.147: E/AndroidRuntime(21108):    at java.lang.reflect.Method.invoke(Method.java:511)
02-19 13:37:08.147: E/AndroidRuntime(21108):    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1007) …
Run Code Online (Sandbox Code Playgroud)

eclipse android crosswalk-runtime

6
推荐指数
2
解决办法
2797
查看次数

cvtColor在转换时崩溃

我将带有外部dll的相机加载到我的OpenCV程序中.我可以看到框架 cv::imshow("edges", frame);,一切都很好.frame.channels()给了我3个频道,但是当我尝试cv::cvtColor(frame, gray, CV_BGR2GRAY);应用程序崩溃时.

CreateImage(System::Byte *imgData, int height, int width,int show)
{

    frame = cv::Mat(height, width, CV_8UC3, imgData);

    if (show > 0)
        cv::imshow("edges", frame); //I can see myself

    return frame.channels(); //three channels
}

void ConvertAndProcess()
{
    cv::Mat gray;

    cv::cvtColor(frame, gray, CV_BGR2GRAY); //crash...

    //do something
}
Run Code Online (Sandbox Code Playgroud)

我已经挖了一段时间但没有结果.我究竟做错了什么?

opencv c++-cli

1
推荐指数
1
解决办法
1834
查看次数

标签 统计

android ×1

c++-cli ×1

crosswalk-runtime ×1

eclipse ×1

opencv ×1