Marker animation along SVG "path" element with D3.js: animating "path" and marker movement synchronously, marker rotate according to tangent line to path.
The MIT License (MIT) | |
Copyright (c) 2014 [KoGor](https://github.com/KoGor) | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is | |
furnished to do so, subject to the following conditions: |
The MIT License (MIT) | |
Copyright (c) 2014 [KoGor](https://github.com/KoGor) | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is | |
furnished to do so, subject to the following conditions: |
/* Terminator.js -- Overlay day/night region on a Leaflet map */ | |
Date.prototype.getJulian = function() { | |
/* Calculate the present UTC Julian Date. Function is valid after | |
* the beginning of the UNIX epoch 1970-01-01 and ignores leap | |
* seconds. */ | |
return (this / 86400000) + 2440587.5; | |
} | |
Date.prototype.getGMST = function() { |
Marker animation along SVG "path" element with D3.js: animating "path" and marker movement synchronously.
Marker animation along SVG "path" element with D3.js Based on Mike's example: Point-Along-Path Interpolation.
SVG "path" element animation with D3.js. Based on Mike's example: Stroke Dash Interpolation.
Globe rotating all the time, click on canvas to unreel/reel. In this example transition is based on interpolation between two projections and map always cut along antimeridian, it creates effect of unreelling/reelling. You can see some artefacts during reeling back to globe, I guess it is because of clipping or timings overlapping, if you have any ideas how to fix it, let me know.
For other variations of transition from Orthographic to Equirectangular and back check these examples:
This projected is licensed under the terms of the MIT license.
Globe rotating manually via drag event, when mouse click event fires - transition begins. For transition backwards use double click on any country. In this example transition is based on interpolation between two projections and map always cut along antimeridian, it creates effect of unreelling/reelling.
For other variations of transition from Orthographic to Equirectangular and back check these examples:
This projected is licensed under the terms of the MIT license.