title: Native method not found: org.opencv.core.Mat.n_Mat:()J
body: <p>I'm using native android Opencv 3.1.0 library
  but always show error like this</p>
  
  <blockquote>
    <p>java.lang.UnsatisfiedLinkError: Native method not found: org.opencv.core.Mat.n_Mat:()J</p>
  </blockquote>
  
  <p>This my Code</p>
  
  <pre><code>package com.example.saya.cameraopencv;
  
  public class Hasil extends AppCompatActivity{
  
  private TextView coba;
  private ImageView gambarskrg;
  private Mat rgba;
  
  final String TAG = "Hello World";
  
  private BaseLoaderCallback mOpenCVCallBack = new BaseLoaderCallback(this) {
      @Override
      public void onManagerConnected(int status) {
          switch (status) {
              case LoaderCallbackInterface.SUCCESS:
              {
                  Log.i(TAG, "OpenCV loaded successfully");           
              } break;
              default:
              {
                  super.onManagerConnected(status);
              } break;
          }
      }
  };
  @Override
  protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.hasil_activity);
      OpenCVLoader.initAsync(OpenCVLoader.OPENCV_VERSION_3_1_0, this, mOpenCVCallBack);
      Bundle i = getIntent().getExtras();
  
      gambarskrg = (ImageView) findViewById(R.id.gambar);
  
      String gambar = Environment.getExternalStorageDirectory()+ "/Coba/Coba_1476987074709.jpg";
  
      Bitmap bmp = BitmapFactory.decodeFile(gambar);
  
      Log.i(TAG, "Trying to load OpenCV library");
      if (!OpenCVLoader.initAsync(OpenCVLoader.OPENCV_VERSION_3_1_0, this, mOpenCVCallBack))
      {
          Log.e(TAG, "Cannot connect to OpenCV Manager");
      }
      else {
          Log.e(TAG, "Berhasil");
          try {
              detectEdges(bmp);
          } catch (Exception e) {
              e.printStackTrace();
          }
      }
  }
  
  private void detectEdges(Bitmap bmp){
      Mat rgba = new Mat();
      Utils.bitmapToMat(bmp, rgba);
  
      Mat edges = new Mat(rgba.size(), CvType.CV_8UC4);
      Imgproc.cvtColor(rgba, edges, Imgproc.COLOR_RGBA2GRAY, 4);
      Imgproc.Canny(edges, edges, 80, 100);
  
      Bitmap resultBitmap = Bitmap.createBitmap(edges.cols(), edges.rows(), Bitmap.Config.ARGB_8888);
      Utils.matToBitmap(edges, resultBitmap);
      int nh = (int) ( resultBitmap.getHeight() * (512.0 / resultBitmap.getWidth()) );
      Bitmap scaled = Bitmap.createScaledBitmap(resultBitmap, 512, nh, true);
      gambarskrg.setImageBitmap(scaled);
  }
  </code></pre>
  
  <p>}</p>
  
  <p>and this the logcat</p>
  
  <blockquote>
    <p>10-21 04:02:32.333 21528-21528/com.example.saya.cameraopencv E/AndroidRuntime: FATAL EXCEPTION: main
                                                                                   Process: com.example.saya.cameraopencv, PID: 21528
                                                                                   java.lang.UnsatisfiedLinkError: Native method not found: org.opencv.core.Mat.n_Mat:()J
                                                                                       at org.opencv.core.Mat.n_Mat(Native Method)
                                                                                       at org.opencv.core.Mat.(Mat.java:24)
                                                                                       at com.example.saya.cameraopencv.Hasil.detectEdges(Hasil.java:88)
                                                                                       at com.example.saya.cameraopencv.Hasil.onCreate(Hasil.java:79)
                                                                                       at android.app.Activity.performCreate(Activity.java)
                                                                                       at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java)
                                                                                       at android.app.ActivityThread.performLaunchActivity(ActivityThread.java)
                                                                                       at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java)
                                                                                       at android.app.ActivityThread.access$800(ActivityThread.java)
                                                                                       at android.app.ActivityThread$H.handleMessage(ActivityThread.java)
                                                                                       at android.os.Handler.dispatchMessage(Handler.java)
                                                                                       at android.os.Looper.loop(Looper.java)
                                                                                       at android.app.ActivityThread.main(ActivityThread.java)
                                                                                       at java.lang.reflect.Method.invokeNative(Native Method)
                                                                                       at java.lang.reflect.Method.invoke(Method.java:515)
                                                                                       at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
                                                                                       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
                                                                                       at de.robv.android.xposed.XposedBridge.main(XposedBridge.java:132)
                                                                                       at dalvik.system.NativeStart.main(Native Method)</p>
  </blockquote>