An error will occur if the following processing.
How should I implement it?
C#
Stream input = Resources.OpenRawResource(Resource.Raw.haarcascade_frontalface_default))
Java.IO.File dir = GetDir("cascade", FileCreationMode.Private);
Java.IO.File file = new Java.IO.File(dir, "haarcascade_frontalface_default.xml");
var output = new FileOutputStream(file);
byte[] buf = new byte[2048];
Output(output, buf);
input.Dispose();
output.Dispose();
string resource = file.AbsolutePath;
var cascade = new CascadeClassifier(resource);