@antv/l7-renderer 2.21.11-beta.1 → 2.21.11-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -60,6 +60,8 @@ var DeviceTexture2D = class {
60
60
  pixelFormat = unorm ? Format.U8_RGBA_NORM : Format.U8_RGBA_RT;
61
61
  } else if (type === gl.UNSIGNED_BYTE && format === gl.LUMINANCE) {
62
62
  pixelFormat = Format.U8_LUMINANCE;
63
+ } else if (type === gl.FLOAT && format === gl.LUMINANCE) {
64
+ pixelFormat = Format.F32_LUMINANCE;
63
65
  } else if (type === gl.FLOAT && format === gl.RGB) {
64
66
  if (this.device.queryVendorInfo().platformString === "WebGPU") {
65
67
  if (data) {
@@ -119,6 +119,13 @@ var DeviceRendererService = class {
119
119
  height,
120
120
  new Uint8Array(width * height * 4)
121
121
  );
122
+ if (this.viewportOrigin !== ViewportOrigin.LOWER_LEFT) {
123
+ for (let j = 0; j < result.length; j += 4) {
124
+ const t = result[j];
125
+ result[j] = result[j + 2];
126
+ result[j + 2] = t;
127
+ }
128
+ }
122
129
  readback.destroy();
123
130
  return result;
124
131
  };
@@ -79,6 +79,8 @@ var DeviceTexture2D = class {
79
79
  pixelFormat = unorm ? import_g_device_api.Format.U8_RGBA_NORM : import_g_device_api.Format.U8_RGBA_RT;
80
80
  } else if (type === import_l7_core.gl.UNSIGNED_BYTE && format === import_l7_core.gl.LUMINANCE) {
81
81
  pixelFormat = import_g_device_api.Format.U8_LUMINANCE;
82
+ } else if (type === import_l7_core.gl.FLOAT && format === import_l7_core.gl.LUMINANCE) {
83
+ pixelFormat = import_g_device_api.Format.F32_LUMINANCE;
82
84
  } else if (type === import_l7_core.gl.FLOAT && format === import_l7_core.gl.RGB) {
83
85
  if (this.device.queryVendorInfo().platformString === "WebGPU") {
84
86
  if (data) {
@@ -143,6 +143,13 @@ var DeviceRendererService = class {
143
143
  height,
144
144
  new Uint8Array(width * height * 4)
145
145
  );
146
+ if (this.viewportOrigin !== import_g_device_api.ViewportOrigin.LOWER_LEFT) {
147
+ for (let j = 0; j < result.length; j += 4) {
148
+ const t = result[j];
149
+ result[j] = result[j + 2];
150
+ result[j + 2] = t;
151
+ }
152
+ }
146
153
  readback.destroy();
147
154
  return result;
148
155
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@antv/l7-renderer",
3
- "version": "2.21.11-beta.1",
3
+ "version": "2.21.11-beta.3",
4
4
  "description": "",
5
5
  "license": "MIT",
6
6
  "author": "https://github.com/orgs/antvis/people",
@@ -16,11 +16,11 @@
16
16
  "@antv/g-device-api": "^1.6.4",
17
17
  "@babel/runtime": "^7.7.7",
18
18
  "regl": "1.6.1",
19
- "@antv/l7-core": "2.21.11-beta.1",
20
- "@antv/l7-utils": "2.21.11-beta.1"
19
+ "@antv/l7-core": "2.21.11-beta.3",
20
+ "@antv/l7-utils": "2.21.11-beta.3"
21
21
  },
22
22
  "devDependencies": {
23
- "@antv/l7-test-utils": "^2.21.11-beta.1"
23
+ "@antv/l7-test-utils": "^2.21.11-beta.3"
24
24
  },
25
25
  "publishConfig": {
26
26
  "access": "public",