@pixwel/pixwel-sdk 2.1.15 → 2.1.17

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.
@@ -119,6 +119,7 @@ var Ingest = function (_Model) {
119
119
  tags: {
120
120
  Usage: null,
121
121
  Aspect: null,
122
+ Standard: null,
122
123
  SubDub: {
123
124
  sub: null,
124
125
  dub: null
@@ -255,6 +256,12 @@ var Ingest = function (_Model) {
255
256
  return part.toUpperCase();
256
257
  });
257
258
 
259
+ // if Aspect and Standard are available, then set the encodeName accoring to naming standard
260
+ if (mediaType == 'video' && tags.Aspect && tags.Standard) {
261
+ var encodeName = tags.Standard.toUpperCase() + "-" + tags.Aspect.replace(':', 'X');
262
+ parts = parts.push("" + encodeName);
263
+ }
264
+
258
265
  var matchedSet = matchSet(allTags, options.tags);
259
266
  var requiredInfo = tags.Resolution && tags["Frame Mode"] && tags.Framerate;
260
267
 
@@ -262,9 +269,6 @@ var Ingest = function (_Model) {
262
269
  parts = parts.push(matchedSet);
263
270
  } else if (mediaType == "video" && tags.Resolution && !requiredInfo) {
264
271
  parts = parts.push(tags.Resolution.replace(/\d+x/, ""));
265
- } else if (mediaType == "video" && tags.Aspect && tags.Standard) {
266
- var encodeName = tags.Standard.toUpperCase() + "-" + tags.Aspect.replace(':', 'X');
267
- parts = parts.push("" + encodeName);
268
272
  } else if (mediaType == "image" && tags.Resolution) {
269
273
  parts = parts.push(tags.Resolution);
270
274
  }
package/npm-update.sh CHANGED
@@ -4,4 +4,5 @@ npm run build
4
4
  npm publish
5
5
 
6
6
  ( cd ../slurpee2 && npm update )
7
+ ( cd ../slurpee3/createFile && npm update )
7
8
  ( cd ../ui && npm update )
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@pixwel/pixwel-sdk",
3
3
  "description": "",
4
- "version": "2.1.15",
4
+ "version": "2.1.17",
5
5
  "author": "Pixwel",
6
6
  "license": "UNLICENSED",
7
7
  "main": "./dist/index.js",
package/src/Ingest.js CHANGED
@@ -70,6 +70,7 @@ export default class Ingest extends Model {
70
70
  tags: {
71
71
  Usage: null,
72
72
  Aspect: null,
73
+ Standard: null,
73
74
  SubDub: {
74
75
  sub: null,
75
76
  dub: null
@@ -226,6 +227,12 @@ export default class Ingest extends Model {
226
227
  .filter()
227
228
  .map(part => part.toUpperCase());
228
229
 
230
+ // if Aspect and Standard are available, then set the encodeName accoring to naming standard
231
+ if (mediaType == 'video' && tags.Aspect && tags.Standard) {
232
+ let encodeName = `${tags.Standard.toUpperCase()}-${tags.Aspect.replace(':', 'X')}`;
233
+ parts = parts.push(`${encodeName}`);
234
+ }
235
+
229
236
  let matchedSet = matchSet(allTags, options.tags);
230
237
  let requiredInfo = tags.Resolution && tags["Frame Mode"] && tags.Framerate;
231
238
 
@@ -233,9 +240,6 @@ export default class Ingest extends Model {
233
240
  parts = parts.push(matchedSet);
234
241
  } else if (mediaType == "video" && tags.Resolution && !requiredInfo) {
235
242
  parts = parts.push(tags.Resolution.replace(/\d+x/, ""));
236
- } else if (mediaType == "video" && tags.Aspect && tags.Standard) {
237
- let encodeName = `${tags.Standard.toUpperCase()}-${tags.Aspect.replace(':', 'X')}`;
238
- parts = parts.push(`${encodeName}`);
239
243
  } else if (mediaType == "image" && tags.Resolution) {
240
244
  parts = parts.push(tags.Resolution);
241
245
  }
@@ -698,14 +698,19 @@ describe("Ingest", () => {
698
698
  language: "ENG",
699
699
  country: "WW",
700
700
  tags: {
701
+ Extra: [],
702
+ SubDub: {
703
+ sub: null,
704
+ dub: null
705
+ },
706
+ Resolution: "720x486",
707
+ Codec: "prores",
708
+ "Frame Mode": "progressive",
709
+ Framerate: "23.98",
701
710
  Standard: "ntsc",
711
+ Usage: "broadcast",
702
712
  Aspect: "16:9",
703
- Resolution: "1920x1080",
704
- "Frame Mode": "progressive",
705
- Framerate: "29.97",
706
- Text: "txtd",
707
- Extra: ["COMING-SOON", "HOJE"],
708
- Codec: "PRORES"
713
+ Text: "txtd"
709
714
  }
710
715
  }
711
716
  }
@@ -716,7 +721,7 @@ describe("Ingest", () => {
716
721
  let extension = "mp4";
717
722
  let name = ingest.renderFilename({ allTags, allTypes, extension });
718
723
  expect(name).toBe(
719
- "TESTPROJECT_ITR-TEST-ASSET-A_ENG_TXTD_COMING-SOON_HOJE_PRORES_NTSC-16X9_1080p2997.mp4"
724
+ "TESTPROJECT_ITR-TEST-ASSET-A_ENG_TXTD_PRORES_NTSC-16X9_486p2398.mp4"
720
725
  );
721
726
  });
722
727
  it("renders `set` tags when all tags in `set` are specified but retains `codec`", function() {