You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: Source/Core/Resource.js
+66-18
Original file line number
Diff line number
Diff line change
@@ -11,6 +11,7 @@ define([
11
11
'./deprecationWarning',
12
12
'./DeveloperError',
13
13
'./freezeObject',
14
+
'./FeatureDetection',
14
15
'./getAbsoluteUri',
15
16
'./getBaseUri',
16
17
'./getExtensionFromUri',
@@ -39,6 +40,7 @@ define([
39
40
deprecationWarning,
40
41
DeveloperError,
41
42
freezeObject,
43
+
FeatureDetection,
42
44
getAbsoluteUri,
43
45
getBaseUri,
44
46
getExtensionFromUri,
@@ -250,6 +252,7 @@ define([
250
252
* @param {Object} [options.templateValues] Key/Value pairs that are used to replace template values (eg. {x}).
251
253
* @param {Object} [options.headers={}] Additional HTTP headers that will be sent.
252
254
* @param {DefaultProxy} [options.proxy] A proxy to be used when loading the resource.
255
+
* @param {Boolean} [options.flipImage] Whether to vertically flip the image during fetch and decode. Only applies when requesting an image and the browser supports createImageBitmap.
253
256
* @param {Resource~RetryCallback} [options.retryCallback] The Function to call when a request for this resource fails. If it returns true, the request will be retried.
254
257
* @param {Number} [options.retryAttempts=0] The number of times the retryCallback should be called before giving up.
255
258
* @param {Request} [options.request] A Request object that will be used. Intended for internal use only.
* @param {Object} [options.templateValues] Key/Value pairs that are used to replace template values (eg. {x}). These will be combined with those of the current instance.
621
632
* @param {Object} [options.headers={}] Additional HTTP headers that will be sent.
622
633
* @param {DefaultProxy} [options.proxy] A proxy to be used when loading the resource.
634
+
* @param {Boolean} [options.flipImage] Whether to vertically flip the image during fetch and decode. Only applies when requesting an image and the browser supports createImageBitmap.
623
635
* @param {Resource~RetryCallback} [options.retryCallback] The function to call when loading the resource fails.
624
636
* @param {Number} [options.retryAttempts] The number of times the retryCallback should be called before giving up.
625
637
* @param {Request} [options.request] A Request object that will be used. Intended for internal use only.
@@ -664,6 +676,9 @@ define([
664
676
if(defined(options.retryAttempts)){
665
677
resource.retryAttempts=options.retryAttempts;
666
678
}
679
+
if(defined(options.flipImage)){
680
+
resource.flipImage=options.flipImage;
681
+
}
667
682
668
683
returnresource;
669
684
};
@@ -714,6 +729,7 @@ define([
714
729
result.retryCallback=this.retryCallback;
715
730
result.retryAttempts=this.retryAttempts;
716
731
result._retryCount=0;
732
+
result.flipImage=this.flipImage;
717
733
result.request=this.request.clone();
718
734
719
735
returnresult;
@@ -771,6 +787,7 @@ define([
771
787
* @param {Object} [options.templateValues] Key/Value pairs that are used to replace template values (eg. {x}).
772
788
* @param {Object} [options.headers={}] Additional HTTP headers that will be sent.
773
789
* @param {DefaultProxy} [options.proxy] A proxy to be used when loading the resource.
790
+
* @param {Boolean} [options.flipImage] Whether to vertically flip the image during fetch and decode. Only applies when requesting an image and the browser supports createImageBitmap.
774
791
* @param {Resource~RetryCallback} [options.retryCallback] The Function to call when a request for this resource fails. If it returns true, the request will be retried.
775
792
* @param {Number} [options.retryAttempts=0] The number of times the retryCallback should be called before giving up.
776
793
* @param {Request} [options.request] A Request object that will be used. Intended for internal use only.
@@ -815,6 +832,7 @@ define([
815
832
* @param {Object} [options.templateValues] Key/Value pairs that are used to replace template values (eg. {x}).
816
833
* @param {Object} [options.headers={}] Additional HTTP headers that will be sent.
817
834
* @param {DefaultProxy} [options.proxy] A proxy to be used when loading the resource.
835
+
* @param {Boolean} [options.flipImage] Whether to vertically flip the image during fetch and decode. Only applies when requesting an image and the browser supports createImageBitmap.
818
836
* @param {Resource~RetryCallback} [options.retryCallback] The Function to call when a request for this resource fails. If it returns true, the request will be retried.
819
837
* @param {Number} [options.retryAttempts=0] The number of times the retryCallback should be called before giving up.
820
838
* @param {Request} [options.request] A Request object that will be used. Intended for internal use only.
* @param {Object} [options.templateValues] Key/Value pairs that are used to replace template values (eg. {x}).
959
980
* @param {Object} [options.headers={}] Additional HTTP headers that will be sent.
960
981
* @param {DefaultProxy} [options.proxy] A proxy to be used when loading the resource.
982
+
* @param {Boolean} [options.flipImage] Whether to vertically flip the image during fetch and decode. Only applies when requesting an image and the browser supports createImageBitmap.
961
983
* @param {Resource~RetryCallback} [options.retryCallback] The Function to call when a request for this resource fails. If it returns true, the request will be retried.
962
984
* @param {Number} [options.retryAttempts=0] The number of times the retryCallback should be called before giving up.
963
985
* @param {Request} [options.request] A Request object that will be used. Intended for internal use only.
@@ -1378,6 +1400,7 @@ define([
1378
1400
* @param {Object} [options.templateValues] Key/Value pairs that are used to replace template values (eg. {x}).
1379
1401
* @param {Object} [options.headers={}] Additional HTTP headers that will be sent.
1380
1402
* @param {DefaultProxy} [options.proxy] A proxy to be used when loading the resource.
1403
+
* @param {Boolean} [options.flipImage] Whether to vertically flip the image during fetch and decode. Only applies when requesting an image and the browser supports createImageBitmap.
1381
1404
* @param {Resource~RetryCallback} [options.retryCallback] The Function to call when a request for this resource fails. If it returns true, the request will be retried.
1382
1405
* @param {Number} [options.retryAttempts=0] The number of times the retryCallback should be called before giving up.
1383
1406
* @param {Request} [options.request] A Request object that will be used. Intended for internal use only.
0 commit comments