Releases: maptalks/maptalks.js
Releases · maptalks/maptalks.js
V0.38.0 Released
Features
-
Increase camera's farZ and draw a fog in far distance, add two new option in map :
fogfogColorto turn on/off fog and indicate fog's color. -
Press ctrl + 0 to reset map's bearing
-
Add array map.cameraUp for map's camera up vector
-
Auto rotate marker with line segment's direction if
markerPlacementisvertex, as #594 , example

-
Support rotate and tilt map by two finger touch gestures, add following new options in map, as #591 :
touchGesture: whether turn on touch gesturetouchRotate: whether turn on touch rotationtouchPitch: whether turn on touch tiltingtouchZoomRotate: turn on to make map rotate and zoom at the same time by touch pinches.
-
Add a new method
getOutlinein geometry, as #598 -
Add a new method
getContainerExtentin geometry -
Add add support of map varibles in function type:
{zoom}{bearing}{pitch}, as #609 -
Add a new option
clipByPitchin TileLayer
Enhancements
- Add LRU Cache in tilelayer, to speed up tiles loading, as #597 , add a new options in TileLayer
maxCacheSizeto set cache's max capacity. - Improved tilelayer's performance by saving gl buffers and using static draw.
- New hit testing strategy with pixel reading, support hit testing of curves or any shape.
- Reuse arrays to save memory in map matrix cacluation.
- Close layer switcher when clicking on map, from #596
- Add default resolutions and full extent for identity projection
- Add rotation sliding, as #581
- Only fire
dragendwhen geometry actually moves, as #610
Fixes
- Fix blank webgl canvas when browser tab visibility changes, as #592
- Fix tilelayer's background painting when rotating
- Fix overview control's baseLayer display in some edge cases, as #600
- Fix tile cancelling in tilelayer gl renderer.
- Fix matrix caculation when map size is 0.
- Fix marker dragging conflicts, as #603
- Fix dragging of geometry with altitude, as #501
- Fix shadow for text inner stroke, as #588
- Fix a bug for updating layer z-index, as #602
- Fix vector layer redraw when map is rotating and zooming
Breaking Changes
- To sync text rotation with map's rotation, change text's rotation direction from count clock wise to clock wise.
markerPlacement : vertexchanges to auto rotate marker with line segment's direction
Contributors
V0.37.0 Released
Features
- Enable
TileLayerto load tiles with different spatial reference from map, as #561- e.g. A map with 4326 projection load tiles of 3857 projection, example
- Add support of base64 images as
linePatternorfillPatternsymbol - Change to draw texthalo with outer stroke instead of inner+outer stroke, as #563
- Add
smoothnessoption in LineString/Polygon to draw line smoothly with bezier curve - Add a uid on map instance, obtained by
map.id - Add two new events
removestartandremoveendto map - Add two new events
tileloadandtileerrortoTileLayer - Add
zoomBackgroundoption inTileLayerto control whether to show a background after zooming - Add
attributionin Layer.options, to display inmaptalks.control.Attribution
Fixes
- Fix screen point projection from world point, when it's behind camera, as #574
- Fix conflict of
map.animateToand scrollZoom - Fix not thrown
viewchangeevent when view hits view history - Fix VectorLayer.setOpacity
- Fix little tail of LineString/Polygon when using DrawTool to draw on mobiles, as #560
- Fix InfoWindow's map events listening
- Fix layer canvas resize on retina screen
- Fix text repaint when geometry's properties is updated, as #570
- Fix zoomable option doesn't work, as in #579
Breaking changes
- Seperate
createContextandcreateCanvasin CanvasRenderer - Remove
shadowoptions in geometry, change to define shadow in symbol, as #577 - Add
createCanvas2inImageGLRenderable, in case another canvas is needed in layer renderer QuadBezierCurvechanges to treat coordinates as control points
Contributors
- @guzhongren for layer attribution
V0.37.0-alpha.1 Released
An alpha release
V0.36.2 Released
Fixes
- Fix an error if geometry returns null paint params in painter
V0.36.0 Released
Features
- Add a new option
dragRotatePitchto enable map to drag to rotate and tilt at the same time.
Example - Add projection parameter in
maptalks.Extentto support extent crossing anti-meridian like from [170, 20] to [-160, 40]
const extent = new maptalks.Extent(170, 20, -160, 40, map.getProjection());
extent.contains([180, 40]); //true- Add a new method
fromProjectionCodeinmaptalks.CRS - Add a new option
removeVertexOningeometry.startEditto customize event to remove a vertex - Extract a new mixin
ImageGLRenderablefromTileLayerGLRenderer - Add
drawTinImageinImageGLRenderable, prepare for some tin painting

Fixes
- Fix a bug when updating spatial reference and swtiching GroupTileLayer's child layer.
Improvements
- Some perf improvement in layer canvas image rendering
V0.35.1 Released
Features
- Add a new control
maptalks.control.LayerSwitcherControl(example). By @1dent1ty in #547 map.addLayersupports rest arguments now- Add a new method
endDrawmethod in DrawTool - Add two method in Layer,
setOpacityandgetOpacity - Reimplement 3D transform matrixes
- Add two new symbol properties
markerHorizontalAlignmentandmarkerVerticalAlignment - Add 4 new event in Map:
rotatestart,rotateend,pitchstartandpitchend - Add 2 new method in Map:
getGLZoomandgetGLScale
Fixes
- Fix several compatible bugs on IE9
- Fix an error to setCoordinates when geometry is being edited, as #551
- Fix event on/off with event map object
- Fix linestring/polygon with altitude's painting
- Fix wrong extent of rectangle with a reversed fullExtent of identity projection
- Fix WMS parameters with WMS version < 1.3.0
- Fix tilelayer's rendering after setting zoom without animation
- Fix infowindow's reopen, as #546
- Fix SVG marker painting on firefox, as #543
- Fix black tile image on IE, as #541
Improments
- TileLayer, change tile texture's min filter to make tile look more clear
Contributors
V0.34.0 Released
V0.33.1 Released
Fixes
- Fix position of marker's auto open infowindow, as #525
V0.33.0 Released
Features
- Add a new option "autoOpenOn" to InfoWindow, as #525
- Add a new event "renderercreate" to Layer
V0.32.4 Released
Fixes
- Reset map's
fpsOnInteractingfrom 0 to 25, as #526


