+ /// Gets or sets whether to apply mask on GPU or not.<br />
+ /// </summary>
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public MaskingModeType MaskingMode
+ {
+ get
+ {
+ return (MaskingModeType)GetValue(MaskingModeProperty);
+ }
+ set
+ {
+ SetValue(MaskingModeProperty, value);
+ NotifyPropertyChanged();
+ }
+ }
+
+ private MaskingModeType InternalMaskingMode
+ {
+ get
+ {
+ int ret = (int)MaskingModeType.MaskingOnLoading;
+
+ PropertyValue maskingMode = GetCachedImageVisualProperty(ImageVisualProperty.MaskingMode);
+ maskingMode?.Get(out ret);
+ maskingMode?.Dispose();
+
+ return (MaskingModeType)ret;
+ }
+ set
+ {
+ MaskingModeType ret = value;
+ PropertyValue setValue = new PropertyValue((int)ret);
+ UpdateImage(ImageVisualProperty.MaskingMode, setValue);
+ setValue?.Dispose();
+ }
+ }
+
+ /// <summary>
+ /// Gets or sets whether to apply fast track uploading or not.<br />
+ /// </summary>
+ /// <remarks>
+ /// If we use fast track uploading feature, It can upload texture without event-thead dependency. But also,<br />
+ /// - Texture size is invalid until ResourceReady signal comes.<br />
+ /// - Texture cannot be cached (We always try to load new image).<br />
+ /// - Seamless visual change didn't supported.<br />
+ /// - Alpha masking didn't supported. If you try, It will load as normal case.<br />
+ /// - Synchronous loading didn't supported. If you try, It will load as normal case.<br />
+ /// - Reload action didn't supported. If you try, It will load as normal case.<br />
+ /// - Atlas loading didn't supported. If you try, It will load as normal case.<br />
+ /// - Custom shader didn't supported. If you try, It will load as normal case.
+ /// </remarks>
+ [EditorBrowsable(EditorBrowsableState.Never)]
+ public bool FastTrackUploading
+ {
+ get
+ {
+ return (bool)GetValue(FastTrackUploadingProperty);
+ }
+ set
+ {
+ SetValue(FastTrackUploadingProperty, value);
+ NotifyPropertyChanged();
+ }
+ }
+
+ private bool InternalFastTrackUploading
+ {
+ get
+ {
+ PropertyValue fastTrackUploading = GetCachedImageVisualProperty(ImageVisualProperty.FastTrackUploading);
+ fastTrackUploading?.Get(out _fastTrackUploading);
+ fastTrackUploading?.Dispose();
+
+ return _fastTrackUploading;
+ }
+ set
+ {
+ if (_fastTrackUploading != value)
+ {
+ _fastTrackUploading = value;
+
+ PropertyValue setValue = new PropertyValue(_fastTrackUploading);
+ UpdateImage(ImageVisualProperty.FastTrackUploading, setValue);
+ setValue?.Dispose();
+
+ if (_fastTrackUploading && !string.IsNullOrEmpty(_resourceUrl))
+ {
+ // Special case. If user set FastTrackUploading mean, user want to upload image As-Soon-As-Possible.
+ // Create ImageVisual synchronously.
+ UpdateImage();
+ }
+ }
+ }
+ }
+
+ /// <summary>