maplibre-gl-layers 0.1.0 → 0.3.0

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.
package/README.md CHANGED
@@ -16,7 +16,7 @@ Markers often need to move smoothly, appear and disappear over time, and you may
16
16
 
17
17
  **maplibre-gl-layers** is designed to meet that need.
18
18
 
19
- Using this package, you can place and adjust large collections of sprites (marker images) through a straightforward API:
19
+ Using this package, you can place and adjust large collections of sprites (marker images) through a straightforward API ([This demo page is here](https://kekyo.github.io/maplibre-gl-layers/)):
20
20
 
21
21
  ![demo 1](images/demo1.png)
22
22
 
@@ -1,11 +1,11 @@
1
1
  /*!
2
2
  * name: maplibre-gl-layers
3
- * version: 0.1.0
3
+ * version: 0.3.0
4
4
  * description: MapLibre's layer extension library enabling the display, movement, and modification of large numbers of dynamic sprite images
5
5
  * author: Kouji Matsui (@kekyo@mi.kekyo.net)
6
6
  * license: MIT
7
7
  * repository.url: https://github.com/kekyo/maplibre-gl-layers.git
8
- * git.commit.hash: 88b09a93779279947d9c6b1e3a7538d4d197dbcb
8
+ * git.commit.hash: fd90d1fd66e4ca9c0defa49e68ecaeb9c14fbd06
9
9
  */
10
10
 
11
11
  import { Map as MapLibreMap } from 'maplibre-gl';
@@ -77,6 +77,10 @@ export declare const compileShader: (glContext: WebGLRenderingContext, type: num
77
77
  * @throws When linking fails or a program cannot be created.
78
78
  */
79
79
  export declare const createShaderProgram: (glContext: WebGLRenderingContext, vertexSource: string, fragmentSource: string) => WebGLProgram;
80
+ type MutableSpriteScreenPoint = {
81
+ x: number;
82
+ y: number;
83
+ };
80
84
  /**
81
85
  * Base attributes for an image that composes a sprite.
82
86
  */
@@ -153,6 +157,15 @@ interface InternalSpriteImageState {
153
157
  * Interpolation state used for offset.offsetDeg.
154
158
  */
155
159
  offsetInterpolationState: NumericInterpolationState | null;
160
+ /**
161
+ * Reusable buffer storing screen-space quad corners for hit testing.
162
+ */
163
+ hitTestCorners?: [
164
+ MutableSpriteScreenPoint,
165
+ MutableSpriteScreenPoint,
166
+ MutableSpriteScreenPoint,
167
+ MutableSpriteScreenPoint
168
+ ];
156
169
  }
157
170
  /**
158
171
  * Sprite position interpolation state.
package/dist/easing.d.ts CHANGED
@@ -1,11 +1,11 @@
1
1
  /*!
2
2
  * name: maplibre-gl-layers
3
- * version: 0.1.0
3
+ * version: 0.3.0
4
4
  * description: MapLibre's layer extension library enabling the display, movement, and modification of large numbers of dynamic sprite images
5
5
  * author: Kouji Matsui (@kekyo@mi.kekyo.net)
6
6
  * license: MIT
7
7
  * repository.url: https://github.com/kekyo/maplibre-gl-layers.git
8
- * git.commit.hash: 88b09a93779279947d9c6b1e3a7538d4d197dbcb
8
+ * git.commit.hash: fd90d1fd66e4ca9c0defa49e68ecaeb9c14fbd06
9
9
  */
10
10
 
11
11
  import { EasingFunction } from './types';