-
Notifications
You must be signed in to change notification settings - Fork 7
Description
Hi, I need to set an image rounded inside a TabView. I need to download an image from the web, to edit it and to save it. This is the code:
http.getImage("https://static.nanopress.it/nanopress/fotogallery/1200X0/240679/super-mario.jpg").then(imageSource` => {
imageSource.saveToFile(this.path, "png");
const filters = new ImageFilters();
const image = new Image();
image.src = this.path;
filters.roundCorner(image, 50).then(img => {
img.saveToFile(this.path, "png");
this.profileTab = { iconSource: this.path };
}).catch(error => {
console.log(error);
});
}).catch(error => {
console.log(error);
});
The function "roundCorner" return this error:
Error: java.lang.IllegalArgumentException: Parameter specified as non-null is null: method kotlin.jvm.internal.Intrinsics.checkParameterIsNotNull, parameter value
net.bradmartin.flexing.ImagesKt.getBitmapFromImageView(Unknown Source:2)
com.tns.Runtime.callJSMethodNative(Native Method)
com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1120)
com.tns.Runtime.callJSMethodImpl(Runtime.java:1000)
com.tns.Runtime.callJSMethod(Runtime.java:987)
com.tns.Runtime.callJSMethod(Runtime.java:967)
com.tns.Runtime.callJSMethod(Runtime.java:959)
com.tns.gen.org.nativescript.widgets.Async_CompleteCallback.onComplete(Async_CompleteCallback.java:17)
org.nativescript.widgets.Async$Http$HttpRequestTask.onPostExecute(Async.java:573) org.nativescript.widgets.Async$Http$1$1.run(Async.java:304)
android.os.Handler.handleCallback(Handler.java:789)
android.os.Handler.dispatchMessage(Handler.java:98)
android.os.Looper.loop(Looper.java:164)
android.app.ActivityThread.main(Activi..
What's the issue?