MCPcopy Create free account
hub / github.com/diffusionstudio/core / createTrack

Method createTrack

src/composition/composition.ts:234–239  ·  view source on GitHub ↗

* Create a track with the given type * @param type the desired type of the track * @returns A new track

(type: T)

Source from the content-addressed store, hash-verified

232 * @returns A new track
233 */
234 public createTrack<T extends TrackType>(type: T) {
235 const track = TrackDeserializer.fromType({ type });
236 this.shiftTrack(track);
237
238 return track;
239 }
240
241 /**
242 * Convenience function for appending a track

Callers 15

addMethod · 0.95
track.spec.tsFile · 0.80
validateFunction · 0.80
caption.spec.tsFile · 0.80
preset.1.spec.tsFile · 0.80
preset.0.spec.tsFile · 0.80

Calls 2

shiftTrackMethod · 0.95
fromTypeMethod · 0.45

Tested by

no test coverage detected