@loaders.gl/video 3.4.14 → 3.4.15
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/dist/es5/bundle.js +1 -1
- package/dist/es5/bundle.js.map +1 -1
- package/dist/es5/gif-builder.js +62 -148
- package/dist/es5/gif-builder.js.map +1 -1
- package/dist/es5/index.js +2 -2
- package/dist/es5/lib/gifshot/gifshot-loader.js +13 -57
- package/dist/es5/lib/gifshot/gifshot-loader.js.map +1 -1
- package/dist/es5/lib/gifshot/gifshot.js +480 -482
- package/dist/es5/lib/gifshot/gifshot.js.map +1 -1
- package/dist/es5/lib/parsers/parse-video.js +5 -23
- package/dist/es5/lib/parsers/parse-video.js.map +1 -1
- package/dist/es5/video-loader.js +6 -6
- package/dist/es5/video-loader.js.map +1 -1
- package/dist/esm/video-loader.js +1 -1
- package/package.json +4 -4
|
@@ -1,31 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
3
|
Object.defineProperty(exports, "__esModule", {
|
|
5
4
|
value: true
|
|
6
5
|
});
|
|
7
6
|
exports.default = parseVideo;
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
function _parseVideo() {
|
|
14
|
-
_parseVideo = (0, _asyncToGenerator2.default)(_regenerator.default.mark(function _callee(arrayBuffer) {
|
|
15
|
-
var blob, video;
|
|
16
|
-
return _regenerator.default.wrap(function _callee$(_context) {
|
|
17
|
-
while (1) switch (_context.prev = _context.next) {
|
|
18
|
-
case 0:
|
|
19
|
-
blob = new Blob([arrayBuffer]);
|
|
20
|
-
video = document.createElement('video');
|
|
21
|
-
video.src = URL.createObjectURL(blob);
|
|
22
|
-
return _context.abrupt("return", video);
|
|
23
|
-
case 4:
|
|
24
|
-
case "end":
|
|
25
|
-
return _context.stop();
|
|
26
|
-
}
|
|
27
|
-
}, _callee);
|
|
28
|
-
}));
|
|
29
|
-
return _parseVideo.apply(this, arguments);
|
|
7
|
+
async function parseVideo(arrayBuffer) {
|
|
8
|
+
const blob = new Blob([arrayBuffer]);
|
|
9
|
+
const video = document.createElement('video');
|
|
10
|
+
video.src = URL.createObjectURL(blob);
|
|
11
|
+
return video;
|
|
30
12
|
}
|
|
31
13
|
//# sourceMappingURL=parse-video.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parse-video.js","names":["parseVideo","
|
|
1
|
+
{"version":3,"file":"parse-video.js","names":["parseVideo","arrayBuffer","blob","Blob","video","document","createElement","src","URL","createObjectURL"],"sources":["../../../../src/lib/parsers/parse-video.ts"],"sourcesContent":["// Parse to platform defined video type (HTMLVideoElement in browser)\nexport default async function parseVideo(arrayBuffer: ArrayBuffer): Promise<HTMLVideoElement> {\n // TODO It is probably somewhat inefficent to convert a File/Blob to ArrayBuffer and back\n // and could perhaps cause problems for large videos.\n // TODO MIME type is also lost from the File or Response...\n const blob = new Blob([arrayBuffer]);\n const video = document.createElement('video');\n video.src = URL.createObjectURL(blob);\n return video;\n}\n"],"mappings":";;;;;;AACe,eAAeA,UAAUA,CAACC,WAAwB,EAA6B;EAI5F,MAAMC,IAAI,GAAG,IAAIC,IAAI,CAAC,CAACF,WAAW,CAAC,CAAC;EACpC,MAAMG,KAAK,GAAGC,QAAQ,CAACC,aAAa,CAAC,OAAO,CAAC;EAC7CF,KAAK,CAACG,GAAG,GAAGC,GAAG,CAACC,eAAe,CAACP,IAAI,CAAC;EACrC,OAAOE,KAAK;AACd"}
|
package/dist/es5/video-loader.js
CHANGED
|
@@ -6,13 +6,13 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports._typecheckVideoLoader = exports.VideoLoader = void 0;
|
|
8
8
|
var _parseVideo = _interopRequireDefault(require("./lib/parsers/parse-video"));
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
9
|
+
const VERSION = typeof "3.4.15" !== 'undefined' ? "3.4.15" : 'latest';
|
|
10
|
+
const EXTENSIONS = ['mp4'];
|
|
11
|
+
const MIME_TYPES = ['video/mp4'];
|
|
12
|
+
const DEFAULT_LOADER_OPTIONS = {
|
|
13
13
|
video: {}
|
|
14
14
|
};
|
|
15
|
-
|
|
15
|
+
const VideoLoader = {
|
|
16
16
|
name: 'Video',
|
|
17
17
|
id: 'video',
|
|
18
18
|
module: 'video',
|
|
@@ -23,6 +23,6 @@ var VideoLoader = {
|
|
|
23
23
|
options: DEFAULT_LOADER_OPTIONS
|
|
24
24
|
};
|
|
25
25
|
exports.VideoLoader = VideoLoader;
|
|
26
|
-
|
|
26
|
+
const _typecheckVideoLoader = VideoLoader;
|
|
27
27
|
exports._typecheckVideoLoader = _typecheckVideoLoader;
|
|
28
28
|
//# sourceMappingURL=video-loader.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"video-loader.js","names":["_parseVideo","_interopRequireDefault","require","VERSION","EXTENSIONS","MIME_TYPES","DEFAULT_LOADER_OPTIONS","video","VideoLoader","name","id","module","version","extensions","mimeTypes","parse","parseVideo","options","exports","_typecheckVideoLoader"],"sources":["../../src/video-loader.ts"],"sourcesContent":["import type {LoaderWithParser, LoaderOptions} from '@loaders.gl/loader-utils';\nimport parseVideo from './lib/parsers/parse-video';\n\n// __VERSION__ is injected by babel-plugin-version-inline\n// @ts-ignore TS2304: Cannot find name '__VERSION__'.\nconst VERSION = typeof __VERSION__ !== 'undefined' ? __VERSION__ : 'latest';\n\nconst EXTENSIONS = ['mp4'];\nconst MIME_TYPES = ['video/mp4'];\n\n// Loads a platform-specific image type that can be used as input data to WebGL textures\n\nexport type VideoLoaderOptions = LoaderOptions & {\n video: {};\n};\n\nconst DEFAULT_LOADER_OPTIONS: VideoLoaderOptions = {\n video: {}\n};\n\nexport const VideoLoader = {\n name: 'Video',\n id: 'video',\n module: 'video',\n version: VERSION,\n extensions: EXTENSIONS,\n mimeTypes: MIME_TYPES,\n\n parse: parseVideo,\n\n // tests: arrayBuffer => Boolean(getBinaryImageMetadata(new DataView(arrayBuffer))),\n options: DEFAULT_LOADER_OPTIONS\n};\n\nexport const _typecheckVideoLoader: LoaderWithParser = VideoLoader;\n"],"mappings":";;;;;;;AACA,IAAAA,WAAA,GAAAC,sBAAA,CAAAC,OAAA;AAIA,
|
|
1
|
+
{"version":3,"file":"video-loader.js","names":["_parseVideo","_interopRequireDefault","require","VERSION","EXTENSIONS","MIME_TYPES","DEFAULT_LOADER_OPTIONS","video","VideoLoader","name","id","module","version","extensions","mimeTypes","parse","parseVideo","options","exports","_typecheckVideoLoader"],"sources":["../../src/video-loader.ts"],"sourcesContent":["import type {LoaderWithParser, LoaderOptions} from '@loaders.gl/loader-utils';\nimport parseVideo from './lib/parsers/parse-video';\n\n// __VERSION__ is injected by babel-plugin-version-inline\n// @ts-ignore TS2304: Cannot find name '__VERSION__'.\nconst VERSION = typeof __VERSION__ !== 'undefined' ? __VERSION__ : 'latest';\n\nconst EXTENSIONS = ['mp4'];\nconst MIME_TYPES = ['video/mp4'];\n\n// Loads a platform-specific image type that can be used as input data to WebGL textures\n\nexport type VideoLoaderOptions = LoaderOptions & {\n video: {};\n};\n\nconst DEFAULT_LOADER_OPTIONS: VideoLoaderOptions = {\n video: {}\n};\n\nexport const VideoLoader = {\n name: 'Video',\n id: 'video',\n module: 'video',\n version: VERSION,\n extensions: EXTENSIONS,\n mimeTypes: MIME_TYPES,\n\n parse: parseVideo,\n\n // tests: arrayBuffer => Boolean(getBinaryImageMetadata(new DataView(arrayBuffer))),\n options: DEFAULT_LOADER_OPTIONS\n};\n\nexport const _typecheckVideoLoader: LoaderWithParser = VideoLoader;\n"],"mappings":";;;;;;;AACA,IAAAA,WAAA,GAAAC,sBAAA,CAAAC,OAAA;AAIA,MAAMC,OAAO,GAAG,eAAkB,KAAK,WAAW,cAAiB,QAAQ;AAE3E,MAAMC,UAAU,GAAG,CAAC,KAAK,CAAC;AAC1B,MAAMC,UAAU,GAAG,CAAC,WAAW,CAAC;AAQhC,MAAMC,sBAA0C,GAAG;EACjDC,KAAK,EAAE,CAAC;AACV,CAAC;AAEM,MAAMC,WAAW,GAAG;EACzBC,IAAI,EAAE,OAAO;EACbC,EAAE,EAAE,OAAO;EACXC,MAAM,EAAE,OAAO;EACfC,OAAO,EAAET,OAAO;EAChBU,UAAU,EAAET,UAAU;EACtBU,SAAS,EAAET,UAAU;EAErBU,KAAK,EAAEC,mBAAU;EAGjBC,OAAO,EAAEX;AACX,CAAC;AAACY,OAAA,CAAAV,WAAA,GAAAA,WAAA;AAEK,MAAMW,qBAAuC,GAAGX,WAAW;AAACU,OAAA,CAAAC,qBAAA,GAAAA,qBAAA"}
|
package/dist/esm/video-loader.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import parseVideo from './lib/parsers/parse-video';
|
|
2
|
-
const VERSION = typeof "3.4.
|
|
2
|
+
const VERSION = typeof "3.4.15" !== 'undefined' ? "3.4.15" : 'latest';
|
|
3
3
|
const EXTENSIONS = ['mp4'];
|
|
4
4
|
const MIME_TYPES = ['video/mp4'];
|
|
5
5
|
const DEFAULT_LOADER_OPTIONS = {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@loaders.gl/video",
|
|
3
|
-
"version": "3.4.
|
|
3
|
+
"version": "3.4.15",
|
|
4
4
|
"description": "Framework-independent loaders and writers for video (MP4, WEBM, ...)",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"publishConfig": {
|
|
@@ -32,9 +32,9 @@
|
|
|
32
32
|
"build-bundle": "esbuild src/bundle.ts --bundle --outfile=dist/dist.min.js"
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@loaders.gl/loader-utils": "3.4.
|
|
36
|
-
"@loaders.gl/worker-utils": "3.4.
|
|
35
|
+
"@loaders.gl/loader-utils": "3.4.15",
|
|
36
|
+
"@loaders.gl/worker-utils": "3.4.15",
|
|
37
37
|
"gifshot": "^0.4.5"
|
|
38
38
|
},
|
|
39
|
-
"gitHead": "
|
|
39
|
+
"gitHead": "19e941d5805568e449ef9092490d6568a4853298"
|
|
40
40
|
}
|