-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgstcontroller-1.0.d.ts
More file actions
870 lines (760 loc) · 32.9 KB
/
gstcontroller-1.0.d.ts
File metadata and controls
870 lines (760 loc) · 32.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
/// <reference path="./gst-1.0.d.ts" />
/// <reference path="./gobject-2.0.d.ts" />
/// <reference path="./glib-2.0.d.ts" />
/// <reference path="./gmodule-2.0.d.ts" />
/**
* Type Definitions for Gjs (https://gjs.guide/)
*
* These type definitions are automatically generated, do not edit them by hand.
* If you found a bug fix it in `ts-for-gir` or create a bug report on https://github.com/gjsify/ts-for-gir
*
* The based EJS template file is used for the generated .d.ts file of each GIR module like Gtk-4.0, GObject-2.0, ...
*/
declare module 'gi://GstController?version=1.0' {
// Module dependencies
import type Gst from 'gi://Gst?version=1.0';
import type GObject from 'gi://GObject?version=2.0';
import type GLib from 'gi://GLib?version=2.0';
import type GModule from 'gi://GModule?version=2.0';
export namespace GstController {
/**
* GstController-1.0
*/
/**
* @gir-type Enum
*/
export namespace InterpolationMode {
export const $gtype: GObject.GType<InterpolationMode>;
}
/**
* The various interpolation modes available.
* @gir-type Enum
*/
enum InterpolationMode {
/**
* steps-like interpolation, default
*/
NONE,
/**
* linear interpolation
*/
LINEAR,
/**
* cubic interpolation (natural), may overshoot
* the min or max values set by the control point, but is more 'curvy'
*/
CUBIC,
/**
* monotonic cubic interpolation, will not
* produce any values outside of the min-max range set by the control points
* (Since: 1.8)
*/
CUBIC_MONOTONIC,
}
/**
* @gir-type Enum
*/
export namespace LFOWaveform {
export const $gtype: GObject.GType<LFOWaveform>;
}
/**
* The various waveform modes available.
* @gir-type Enum
*/
enum LFOWaveform {
/**
* sine waveform
*/
SINE,
/**
* square waveform
*/
SQUARE,
/**
* saw waveform
*/
SAW,
/**
* reverse saw waveform
*/
REVERSE_SAW,
/**
* triangle waveform
*/
TRIANGLE,
}
/**
* Reset the controlled value cache.
* @param self the {@link GstController.TimedValueControlSource}
*/
function timed_value_control_invalidate_cache(self: TimedValueControlSource): void;
/**
* @gir-type Callback
*/
interface DirectControlBindingConvertGValue {
(self: DirectControlBinding, src_value: number, dest_value: unknown): void;
}
/**
* @gir-type Callback
*/
interface DirectControlBindingConvertValue {
(self: DirectControlBinding, src_value: number, dest_value?: any | null): void;
}
namespace ARGBControlBinding {
// Signal signatures
interface SignalSignatures extends Gst.ControlBinding.SignalSignatures {
'notify::control-source-a': (pspec: GObject.ParamSpec) => void;
'notify::control-source-b': (pspec: GObject.ParamSpec) => void;
'notify::control-source-g': (pspec: GObject.ParamSpec) => void;
'notify::control-source-r': (pspec: GObject.ParamSpec) => void;
'notify::name': (pspec: GObject.ParamSpec) => void;
'notify::object': (pspec: GObject.ParamSpec) => void;
'notify::parent': (pspec: GObject.ParamSpec) => void;
}
// Constructor properties interface
interface ConstructorProps extends Gst.ControlBinding.ConstructorProps {
control_source_a: Gst.ControlSource;
controlSourceA: Gst.ControlSource;
control_source_b: Gst.ControlSource;
controlSourceB: Gst.ControlSource;
control_source_g: Gst.ControlSource;
controlSourceG: Gst.ControlSource;
control_source_r: Gst.ControlSource;
controlSourceR: Gst.ControlSource;
}
}
/**
* A value mapping object that attaches multiple control sources to a guint
* gobject properties representing a color. A control value of 0.0 will turn the
* color component off and a value of 1.0 will be the color level.
* @gir-type Class
*/
class ARGBControlBinding extends Gst.ControlBinding {
static $gtype: GObject.GType<ARGBControlBinding>;
// Properties
get control_source_a(): Gst.ControlSource;
set control_source_a(val: Gst.ControlSource);
get controlSourceA(): Gst.ControlSource;
set controlSourceA(val: Gst.ControlSource);
get control_source_b(): Gst.ControlSource;
set control_source_b(val: Gst.ControlSource);
get controlSourceB(): Gst.ControlSource;
set controlSourceB(val: Gst.ControlSource);
get control_source_g(): Gst.ControlSource;
set control_source_g(val: Gst.ControlSource);
get controlSourceG(): Gst.ControlSource;
set controlSourceG(val: Gst.ControlSource);
get control_source_r(): Gst.ControlSource;
set control_source_r(val: Gst.ControlSource);
get controlSourceR(): Gst.ControlSource;
set controlSourceR(val: Gst.ControlSource);
/**
* Compile-time signal type information.
*
* This instance property is generated only for TypeScript type checking.
* It is not defined at runtime and should not be accessed in JS code.
* @internal
*/
$signals: ARGBControlBinding.SignalSignatures;
// Constructors
constructor(properties?: Partial<ARGBControlBinding.ConstructorProps>, ...args: any[]);
_init(...args: any[]): void;
static ['new'](
object: Gst.Object,
property_name: string,
cs_a: Gst.ControlSource,
cs_r: Gst.ControlSource,
cs_g: Gst.ControlSource,
cs_b: Gst.ControlSource,
): ARGBControlBinding;
// Signals
/** @signal */
connect<K extends keyof ARGBControlBinding.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, ARGBControlBinding.SignalSignatures[K]>,
): number;
connect(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
connect_after<K extends keyof ARGBControlBinding.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, ARGBControlBinding.SignalSignatures[K]>,
): number;
connect_after(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
emit<K extends keyof ARGBControlBinding.SignalSignatures>(
signal: K,
...args: GObject.GjsParameters<ARGBControlBinding.SignalSignatures[K]> extends [any, ...infer Q]
? Q
: never
): void;
emit(signal: string, ...args: any[]): void;
}
namespace DirectControlBinding {
// Signal signatures
interface SignalSignatures extends Gst.ControlBinding.SignalSignatures {
'notify::absolute': (pspec: GObject.ParamSpec) => void;
'notify::control-source': (pspec: GObject.ParamSpec) => void;
'notify::name': (pspec: GObject.ParamSpec) => void;
'notify::object': (pspec: GObject.ParamSpec) => void;
'notify::parent': (pspec: GObject.ParamSpec) => void;
}
// Constructor properties interface
interface ConstructorProps extends Gst.ControlBinding.ConstructorProps {
absolute: boolean;
control_source: Gst.ControlSource;
controlSource: Gst.ControlSource;
}
}
/**
* A value mapping object that attaches control sources to gobject properties. It
* will map the control values directly to the target property range. If a
* non-absolute direct control binding is used, the value range [0.0 ... 1.0]
* is mapped to full target property range, and all values outside the range
* will be clipped. An absolute control binding will not do any value
* transformations.
* @gir-type Class
*/
class DirectControlBinding extends Gst.ControlBinding {
static $gtype: GObject.GType<DirectControlBinding>;
// Properties
/**
* @construct-only
*/
get absolute(): boolean;
get control_source(): Gst.ControlSource;
set control_source(val: Gst.ControlSource);
get controlSource(): Gst.ControlSource;
set controlSource(val: Gst.ControlSource);
/**
* Compile-time signal type information.
*
* This instance property is generated only for TypeScript type checking.
* It is not defined at runtime and should not be accessed in JS code.
* @internal
*/
$signals: DirectControlBinding.SignalSignatures;
// Constructors
constructor(properties?: Partial<DirectControlBinding.ConstructorProps>, ...args: any[]);
_init(...args: any[]): void;
static ['new'](object: Gst.Object, property_name: string, cs: Gst.ControlSource): DirectControlBinding;
static new_absolute(object: Gst.Object, property_name: string, cs: Gst.ControlSource): DirectControlBinding;
// Signals
/** @signal */
connect<K extends keyof DirectControlBinding.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, DirectControlBinding.SignalSignatures[K]>,
): number;
connect(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
connect_after<K extends keyof DirectControlBinding.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, DirectControlBinding.SignalSignatures[K]>,
): number;
connect_after(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
emit<K extends keyof DirectControlBinding.SignalSignatures>(
signal: K,
...args: GObject.GjsParameters<DirectControlBinding.SignalSignatures[K]> extends [any, ...infer Q]
? Q
: never
): void;
emit(signal: string, ...args: any[]): void;
}
namespace InterpolationControlSource {
// Signal signatures
interface SignalSignatures extends TimedValueControlSource.SignalSignatures {
'notify::mode': (pspec: GObject.ParamSpec) => void;
'notify::name': (pspec: GObject.ParamSpec) => void;
'notify::parent': (pspec: GObject.ParamSpec) => void;
}
// Constructor properties interface
interface ConstructorProps extends TimedValueControlSource.ConstructorProps {
mode: InterpolationMode;
}
}
/**
* {@link GstController.InterpolationControlSource} is a {@link Gst.ControlSource}, that interpolates values between user-given
* control points. It supports several interpolation modes and property types.
*
* To use {@link GstController.InterpolationControlSource} get a new instance by calling
* `gst_interpolation_control_source_new()`, bind it to a {@link GObject.ParamSpec} and set some
* control points by calling `gst_timed_value_control_source_set()`.
*
* All functions are MT-safe.
* @gir-type Class
*/
class InterpolationControlSource extends TimedValueControlSource {
static $gtype: GObject.GType<InterpolationControlSource>;
// Properties
get mode(): InterpolationMode;
set mode(val: InterpolationMode);
/**
* Compile-time signal type information.
*
* This instance property is generated only for TypeScript type checking.
* It is not defined at runtime and should not be accessed in JS code.
* @internal
*/
$signals: InterpolationControlSource.SignalSignatures;
// Constructors
constructor(properties?: Partial<InterpolationControlSource.ConstructorProps>, ...args: any[]);
_init(...args: any[]): void;
static ['new'](): InterpolationControlSource;
// Signals
/** @signal */
connect<K extends keyof InterpolationControlSource.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, InterpolationControlSource.SignalSignatures[K]>,
): number;
connect(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
connect_after<K extends keyof InterpolationControlSource.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, InterpolationControlSource.SignalSignatures[K]>,
): number;
connect_after(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
emit<K extends keyof InterpolationControlSource.SignalSignatures>(
signal: K,
...args: GObject.GjsParameters<InterpolationControlSource.SignalSignatures[K]> extends [any, ...infer Q]
? Q
: never
): void;
emit(signal: string, ...args: any[]): void;
}
namespace LFOControlSource {
// Signal signatures
interface SignalSignatures extends Gst.ControlSource.SignalSignatures {
'notify::amplitude': (pspec: GObject.ParamSpec) => void;
'notify::frequency': (pspec: GObject.ParamSpec) => void;
'notify::offset': (pspec: GObject.ParamSpec) => void;
'notify::timeshift': (pspec: GObject.ParamSpec) => void;
'notify::waveform': (pspec: GObject.ParamSpec) => void;
'notify::name': (pspec: GObject.ParamSpec) => void;
'notify::parent': (pspec: GObject.ParamSpec) => void;
}
// Constructor properties interface
interface ConstructorProps extends Gst.ControlSource.ConstructorProps {
amplitude: number;
frequency: number;
offset: number;
timeshift: bigint | number;
waveform: LFOWaveform;
}
}
/**
* {@link GstController.LFOControlSource} is a {@link Gst.ControlSource}, that provides several periodic
* waveforms as control values.
*
* To use {@link GstController.LFOControlSource} get a new instance by calling
* `gst_lfo_control_source_new()`, bind it to a {@link GObject.ParamSpec} and set the relevant
* properties.
*
* All functions are MT-safe.
* @gir-type Class
*/
class LFOControlSource extends Gst.ControlSource {
static $gtype: GObject.GType<LFOControlSource>;
// Properties
/**
* Specifies the amplitude for the waveform of this {@link GstController.LFOControlSource}.
*/
get amplitude(): number;
set amplitude(val: number);
/**
* Specifies the frequency that should be used for the waveform
* of this {@link GstController.LFOControlSource}. It should be large enough
* so that the period is longer than one nanosecond.
*/
get frequency(): number;
set frequency(val: number);
/**
* Specifies the value offset for the waveform of this {@link GstController.LFOControlSource}.
*/
get offset(): number;
set offset(val: number);
/**
* Specifies the timeshift to the right that should be used for the waveform
* of this {@link GstController.LFOControlSource} in nanoseconds.
*
* To get a n nanosecond shift to the left use
* "(GST_SECOND / frequency) - n".
*/
get timeshift(): number;
set timeshift(val: bigint | number);
/**
* Specifies the waveform that should be used for this {@link GstController.LFOControlSource}.
*/
get waveform(): LFOWaveform;
set waveform(val: LFOWaveform);
/**
* Compile-time signal type information.
*
* This instance property is generated only for TypeScript type checking.
* It is not defined at runtime and should not be accessed in JS code.
* @internal
*/
$signals: LFOControlSource.SignalSignatures;
// Constructors
constructor(properties?: Partial<LFOControlSource.ConstructorProps>, ...args: any[]);
_init(...args: any[]): void;
static ['new'](): LFOControlSource;
// Signals
/** @signal */
connect<K extends keyof LFOControlSource.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, LFOControlSource.SignalSignatures[K]>,
): number;
connect(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
connect_after<K extends keyof LFOControlSource.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, LFOControlSource.SignalSignatures[K]>,
): number;
connect_after(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
emit<K extends keyof LFOControlSource.SignalSignatures>(
signal: K,
...args: GObject.GjsParameters<LFOControlSource.SignalSignatures[K]> extends [any, ...infer Q]
? Q
: never
): void;
emit(signal: string, ...args: any[]): void;
}
namespace ProxyControlBinding {
// Signal signatures
interface SignalSignatures extends Gst.ControlBinding.SignalSignatures {
'notify::name': (pspec: GObject.ParamSpec) => void;
'notify::object': (pspec: GObject.ParamSpec) => void;
'notify::parent': (pspec: GObject.ParamSpec) => void;
}
// Constructor properties interface
interface ConstructorProps extends Gst.ControlBinding.ConstructorProps {}
}
/**
* A {@link Gst.ControlBinding} that forwards requests to another {@link Gst.ControlBinding}
* @gir-type Class
*/
class ProxyControlBinding extends Gst.ControlBinding {
static $gtype: GObject.GType<ProxyControlBinding>;
/**
* Compile-time signal type information.
*
* This instance property is generated only for TypeScript type checking.
* It is not defined at runtime and should not be accessed in JS code.
* @internal
*/
$signals: ProxyControlBinding.SignalSignatures;
// Constructors
constructor(properties?: Partial<ProxyControlBinding.ConstructorProps>, ...args: any[]);
_init(...args: any[]): void;
static ['new'](
object: Gst.Object,
property_name: string,
ref_object: Gst.Object,
ref_property_name: string,
): ProxyControlBinding;
// Signals
/** @signal */
connect<K extends keyof ProxyControlBinding.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, ProxyControlBinding.SignalSignatures[K]>,
): number;
connect(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
connect_after<K extends keyof ProxyControlBinding.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, ProxyControlBinding.SignalSignatures[K]>,
): number;
connect_after(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
emit<K extends keyof ProxyControlBinding.SignalSignatures>(
signal: K,
...args: GObject.GjsParameters<ProxyControlBinding.SignalSignatures[K]> extends [any, ...infer Q]
? Q
: never
): void;
emit(signal: string, ...args: any[]): void;
}
namespace TimedValueControlSource {
// Signal signatures
interface SignalSignatures extends Gst.ControlSource.SignalSignatures {
/**
* Emitted right after the new value has been added to `self`
* @signal
* @since 1.6
* @run-first
*/
'value-added': (arg0: ControlPoint) => void;
/**
* Emitted right after the new value has been set on `timed_signals`
* @signal
* @since 1.6
* @run-first
*/
'value-changed': (arg0: ControlPoint) => void;
/**
* Emitted when `timed_value` is removed from `self`
* @signal
* @since 1.6
* @run-first
*/
'value-removed': (arg0: ControlPoint) => void;
'notify::name': (pspec: GObject.ParamSpec) => void;
'notify::parent': (pspec: GObject.ParamSpec) => void;
}
// Constructor properties interface
interface ConstructorProps extends Gst.ControlSource.ConstructorProps {}
}
/**
* Base class for {@link Gst.ControlSource} that use time-stamped values.
*
* When overriding bind, chain up first to give this bind implementation a
* chance to setup things.
*
* All functions are MT-safe.
* @gir-type Class
*/
abstract class TimedValueControlSource extends Gst.ControlSource {
static $gtype: GObject.GType<TimedValueControlSource>;
/**
* Compile-time signal type information.
*
* This instance property is generated only for TypeScript type checking.
* It is not defined at runtime and should not be accessed in JS code.
* @internal
*/
$signals: TimedValueControlSource.SignalSignatures;
// Fields
nvalues: number;
valid_cache: boolean;
// Constructors
constructor(properties?: Partial<TimedValueControlSource.ConstructorProps>, ...args: any[]);
_init(...args: any[]): void;
// Signals
/** @signal */
connect<K extends keyof TimedValueControlSource.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, TimedValueControlSource.SignalSignatures[K]>,
): number;
connect(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
connect_after<K extends keyof TimedValueControlSource.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, TimedValueControlSource.SignalSignatures[K]>,
): number;
connect_after(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
emit<K extends keyof TimedValueControlSource.SignalSignatures>(
signal: K,
...args: GObject.GjsParameters<TimedValueControlSource.SignalSignatures[K]> extends [any, ...infer Q]
? Q
: never
): void;
emit(signal: string, ...args: any[]): void;
// Methods
/**
* Find last value before given timestamp in control point list.
* If all values in the control point list come after the given
* timestamp or no values exist, `null` is returned.
*
* For use in control source implementations.
* @param timestamp the search key
* @returns the found {@link GLib.SequenceIter} or `null`
*/
find_control_point_iter(timestamp: Gst.ClockTime): GLib.SequenceIter | null;
/**
* Returns a read-only copy of the list of {@link GstController.ControlPoint} for the given property.
* Free the list after done with it.
* @returns a copy of the list, or `null` if the property isn't handled by the controller
*/
get_all(): ControlPoint[];
/**
* Get the number of control points that are set.
* @returns the number of control points that are set.
*/
get_count(): number;
/**
* Set the value of given controller-handled property at a certain time.
* @param timestamp the time the control-change is scheduled for
* @param value the control-value
* @returns FALSE if the values couldn't be set, TRUE otherwise.
*/
set(timestamp: Gst.ClockTime, value: number): boolean;
/**
* @param args
*/
// Conflicted with GObject.Object.set
set(...args: never[]): any;
/**
* Sets multiple timed values at once.
* @param timedvalues a list with {@link Gst.TimedValue} items
* @returns FALSE if the values couldn't be set, TRUE otherwise.
*/
set_from_list(timedvalues: Gst.TimedValue[]): boolean;
/**
* Used to remove the value of given controller-handled property at a certain
* time.
* @param timestamp the time the control-change should be removed from
* @returns FALSE if the value couldn't be unset (i.e. not found, TRUE otherwise.
*/
unset(timestamp: Gst.ClockTime): boolean;
/**
* Used to remove all time-stamped values of given controller-handled property
*/
unset_all(): void;
}
namespace TriggerControlSource {
// Signal signatures
interface SignalSignatures extends TimedValueControlSource.SignalSignatures {
'notify::tolerance': (pspec: GObject.ParamSpec) => void;
'notify::name': (pspec: GObject.ParamSpec) => void;
'notify::parent': (pspec: GObject.ParamSpec) => void;
}
// Constructor properties interface
interface ConstructorProps extends TimedValueControlSource.ConstructorProps {
tolerance: bigint | number;
}
}
/**
* {@link GstController.TriggerControlSource} is a {@link Gst.ControlSource}, that returns values from user-given
* control points. It allows for a tolerance on the time-stamps.
*
* To use {@link GstController.TriggerControlSource} get a new instance by calling
* `gst_trigger_control_source_new()`, bind it to a {@link GObject.ParamSpec} and set some
* control points by calling `gst_timed_value_control_source_set()`.
*
* All functions are MT-safe.
* @gir-type Class
*/
class TriggerControlSource extends TimedValueControlSource {
static $gtype: GObject.GType<TriggerControlSource>;
// Properties
get tolerance(): number;
set tolerance(val: bigint | number);
/**
* Compile-time signal type information.
*
* This instance property is generated only for TypeScript type checking.
* It is not defined at runtime and should not be accessed in JS code.
* @internal
*/
$signals: TriggerControlSource.SignalSignatures;
// Constructors
constructor(properties?: Partial<TriggerControlSource.ConstructorProps>, ...args: any[]);
_init(...args: any[]): void;
static ['new'](): TriggerControlSource;
// Signals
/** @signal */
connect<K extends keyof TriggerControlSource.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, TriggerControlSource.SignalSignatures[K]>,
): number;
connect(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
connect_after<K extends keyof TriggerControlSource.SignalSignatures>(
signal: K,
callback: GObject.SignalCallback<this, TriggerControlSource.SignalSignatures[K]>,
): number;
connect_after(signal: string, callback: (...args: any[]) => any): number;
/** @signal */
emit<K extends keyof TriggerControlSource.SignalSignatures>(
signal: K,
...args: GObject.GjsParameters<TriggerControlSource.SignalSignatures[K]> extends [any, ...infer Q]
? Q
: never
): void;
emit(signal: string, ...args: any[]): void;
}
/**
* @gir-type Alias
*/
type ARGBControlBindingClass = typeof ARGBControlBinding;
/**
* An internal structure for value+time and various temporary
* values used for interpolation. This "inherits" from
* GstTimedValue.
* @gir-type Struct
*/
class ControlPoint {
static $gtype: GObject.GType<ControlPoint>;
// Fields
timestamp: Gst.ClockTime;
value: number;
// Methods
/**
* Copies a {@link GstController.ControlPoint}
* @returns A copy of `cp`
*/
copy(): ControlPoint;
/**
* Frees all data allocated by a {@link GstController.ControlPoint} instance.
*/
free(): void;
}
/**
* @gir-type Alias
*/
type DirectControlBindingClass = typeof DirectControlBinding;
/**
* @gir-type Alias
*/
type InterpolationControlSourceClass = typeof InterpolationControlSource;
/**
* @gir-type Struct
*/
abstract class InterpolationControlSourcePrivate {
static $gtype: GObject.GType<InterpolationControlSourcePrivate>;
}
/**
* @gir-type Alias
*/
type LFOControlSourceClass = typeof LFOControlSource;
/**
* @gir-type Struct
*/
abstract class LFOControlSourcePrivate {
static $gtype: GObject.GType<LFOControlSourcePrivate>;
}
/**
* @gir-type Alias
*/
type ProxyControlBindingClass = typeof ProxyControlBinding;
/**
* @gir-type Alias
*/
type TimedValueControlSourceClass = typeof TimedValueControlSource;
/**
* @gir-type Struct
*/
abstract class TimedValueControlSourcePrivate {
static $gtype: GObject.GType<TimedValueControlSourcePrivate>;
}
/**
* @gir-type Alias
*/
type TriggerControlSourceClass = typeof TriggerControlSource;
/**
* @gir-type Struct
*/
abstract class TriggerControlSourcePrivate {
static $gtype: GObject.GType<TriggerControlSourcePrivate>;
}
/**
* Name of the imported GIR library
* `see` https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L188
*/
const __name__: string;
/**
* Version of the imported GIR library
* `see` https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L189
*/
const __version__: string;
}
export default GstController;
}
declare module 'gi://GstController' {
import GstController10 from 'gi://GstController?version=1.0';
export default GstController10;
}
// END