summaryrefslogblamecommitdiffstats
path: root/sdk/dx8sdk/Include/DShowIDL/qedit.idl
blob: b75a3e357ff43ee0fab89783a022a4b1bb258c35 (plain) (tree)
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
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734





































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































































                                                                                                                                                      
//------------------------------------------------------------------------------
// File: QEdit.idl
//
// Copyright (c) 1992 - 2002, Microsoft Corporation.  All rights reserved.
//------------------------------------------------------------------------------


import "oaidl.idl";
import "ocidl.idl";
import "dxtrans.idl";
import "amstream.idl";
import "msxml.idl";

//
// forward declare
//
interface IAMTimelineGroup;
interface IAMTimelineObj;
interface IAMTimelineEffect;
interface IAMTimelineTrans;
interface IAMTimelineSrc;
interface IAMTimeline;
interface IAMErrorLog;
interface ISampleGrabber;
interface IPropertySetter;

// used by DEXTER_VALUE's dwInterp var
typedef enum
{
    DEXTERF_JUMP,
    DEXTERF_INTERPOLATE
} DEXTERF;

// used to set values on the property setter
typedef struct
{
    BSTR Name;
    DISPID dispID;
    LONG nValues;
} DEXTER_PARAM;

// used to set values on the property setter
typedef struct
{
    VARIANT v;
    REFERENCE_TIME rt;
    DWORD dwInterp;    // one of the DEXTERF_ flags
} DEXTER_VALUE;

// used by bMethod directly below
enum
{
    DEXTER_AUDIO_JUMP,
    DEXTER_AUDIO_INTERPOLATE
};

// used to set volumes on the mixer and mixer pins
typedef struct
{
    REFERENCE_TIME        rtEnd;        //end Time
    double                dLevel;    //end Volume Level
    BOOL                bMethod;    //jump or interpolate
} DEXTER_AUDIO_VOLUMEENVELOPE ;

// used in IAMTimeline::Get(Set)InsertMode
enum
{
    TIMELINE_INSERT_MODE_INSERT = 1,
    TIMELINE_INSERT_MODE_OVERLAY = 2
};

//
// define what main 'things' can be put into the timeline tree.
// these values are used quite a bit with timeline access
// (bitmap mask flags)
typedef enum
{
    TIMELINE_MAJOR_TYPE_COMPOSITE = 1,
    TIMELINE_MAJOR_TYPE_TRACK = 2,
    TIMELINE_MAJOR_TYPE_SOURCE = 4,
    TIMELINE_MAJOR_TYPE_TRANSITION = 8,
    TIMELINE_MAJOR_TYPE_EFFECT = 16,
    TIMELINE_MAJOR_TYPE_GROUP = 128
} TIMELINE_MAJOR_TYPE;

// used in various IAMTimelineXXX "search" functions. Look in this
// file for "SearchDirection" to see where it's used. I didn't want
// to use an enum as an interface param type, so I used a long. 
typedef enum
{
    DEXTERF_BOUNDING = -1,        // finds any source whose start <= Time and stop > Time
    DEXTERF_EXACTLY_AT = 0,        // finds any source that starts exactly at Time
    DEXTERF_FORWARDS = 1        // finds any source that starts at or after Time
} DEXTERF_TRACK_SEARCH_FLAGS;

// right now, the media type in the group contains enough information about
// how we want to recompress. This might not be enough information in the 
// future, so we define a structure we can get and set to the group. 
//
typedef struct _SCompFmt0
{
    long nFormatId;
    AM_MEDIA_TYPE MediaType;
} SCompFmt0;

// used in IAMTimelineSrc::Get(Set)StretchMode
// 
enum
{
    RESIZEF_STRETCH,
    RESIZEF_CROP,
    RESIZEF_PRESERVEASPECTRATIO,
    RESIZEF_PRESERVEASPECTRATIO_NOLETTERBOX
};

// used in IRenderEngine::SetDynamicReconnectLevel
// (bitmap mask flags)
enum
{
    CONNECTF_DYNAMIC_NONE = 0x00000000,
    CONNECTF_DYNAMIC_SOURCES = 0x00000001,
    CONNECTF_DYNAMIC_EFFECTS = 0x00000002
};

// used in
// IMediaLocator::FindMediaFile
// IRenderEngine::SetSourceNameValidation
// IAMTimeline::ValidateSourceNames
// (bitmap mask flags)
enum
{
    SFN_VALIDATEF_CHECK        = 0x00000001,   // do a check. Without this set, no check will be done.
    SFN_VALIDATEF_POPUP        = 0x00000002,   // should UI popup show if not found
    SFN_VALIDATEF_TELLME       = 0x00000004,   // warn user about replaced files
    SFN_VALIDATEF_REPLACE      = 0x00000008,   // should it replace names in the tldb if found
    SFN_VALIDATEF_USELOCAL     = 0x000000010,  // use local media preferrably over networked media
    SFN_VALIDATEF_NOFIND       = 0x000000020,  // never find filenames, always use UI popup to find.,
                                               // when used, _POPUP must be used as well
    SFN_VALIDATEF_IGNOREMUTED  = 0x000000040,  // ignore muted files in the tldb
    SFN_VALIDATEF_END
};

// key transitions types
enum
{
    DXTKEY_RGB,        
    DXTKEY_NONRED,         
    DXTKEY_LUMINANCE,      
    DXTKEY_ALPHA,          
    DXTKEY_HUE
};


////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////
// New Property setting Interfaces
////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////

// interface for objects which can save/load IDispatch-able properties
[
    object,
    uuid(AE9472BD-B0C3-11D2-8D24-00A0C9441E20),
    helpstring("IPropertySetter Interface"),
    pointer_default(unique)
]
interface IPropertySetter : IUnknown // IPersist?
{
    // for loading and saving through XML
    HRESULT LoadXML([in] IUnknown * pxml);
    // !!! doesn't work HRESULT LoadXML([in] IXMLElement * pxml);
    HRESULT PrintXML([out] char *pszXML, [in] int cbXML, [out] int *pcbPrinted,[in] int indent);
         
    // for cloning a portion of the props when splitting the object
    //AUTOMATE
    HRESULT CloneProps([out] IPropertySetter **ppSetter,
            [in] REFERENCE_TIME rtStart,
            [in] REFERENCE_TIME rtStop);

    // for loading and saving programmatically
    // caller must call this in pre-sorted order, this time must be > all
    // previous times
    //AUTOMATE
    HRESULT AddProp([in] DEXTER_PARAM Param,
            [in] DEXTER_VALUE *paValue);
    //AUTOMATE
    HRESULT GetProps([out] LONG *pcParams,
             [out] DEXTER_PARAM **paParam,
            [out] DEXTER_VALUE **paValue);
    // after calling GetProps, you must call FreeProps to free resources
    //AUTOMATE
    HRESULT FreeProps([in] LONG cParams,
            [in] DEXTER_PARAM *paParam,
            [in] DEXTER_VALUE *paValue);
    // to empty to property setter, so you can start over again
    HRESULT ClearProps();

    // for persisting
    HRESULT SaveToBlob([out] LONG *pcSize, [out] BYTE **ppb);
    HRESULT LoadFromBlob([in] LONG cSize, [in] BYTE *pb);

    // to program the object that supports IDispatch with the props
    // call with rtNow == -1 to set Static Props when your object instantiates
    // errors will be logged, if a log is provided
    //AUTOMATE
    HRESULT SetProps([in] IUnknown *pTarget,
            [in] REFERENCE_TIME rtNow);

    // unicode version
    HRESULT PrintXMLW([out] WCHAR *pszXML, [in] int cchXML, [out] int *pcchPrinted,[in] int indent);
};

// supported by our DxtCompositor class, this allows us to draw whatever comes in
// upon only a portion of the output bitmap

[
    object,
    uuid(BB44391E-6ABD-422f-9E2E-385C9DFF51FC),
    dual,
    helpstring("IDxtCompositor Interface"),
    pointer_default(unique)
]
interface IDxtCompositor : IDXEffect
{
    [propget, id(1), helpstring("property OffsetX")] HRESULT OffsetX([out, retval] long *pVal);
    [propput, id(1), helpstring("property OffsetX")] HRESULT OffsetX([in] long newVal);
    [propget, id(2), helpstring("property OffsetY")] HRESULT OffsetY([out, retval] long *pVal);
    [propput, id(2), helpstring("property OffsetY")] HRESULT OffsetY([in] long newVal);
    [propget, id(3), helpstring("property Width")] HRESULT Width([out, retval] long *pVal);
    [propput, id(3), helpstring("property Width")] HRESULT Width([in] long newVal);
    [propget, id(4), helpstring("property Height")] HRESULT Height([out, retval] long *pVal);
    [propput, id(4), helpstring("property Height")] HRESULT Height([in] long newVal);

    [propget, id(5), helpstring("property SrcOffsetX")] HRESULT SrcOffsetX([out, retval] long *pVal);
    [propput, id(5), helpstring("property SrcOffsetX")] HRESULT SrcOffsetX([in] long newVal);
    [propget, id(6), helpstring("property SrcOffsetY")] HRESULT SrcOffsetY([out, retval] long *pVal);
    [propput, id(6), helpstring("property SrcOffsetY")] HRESULT SrcOffsetY([in] long newVal);
    [propget, id(7), helpstring("property SrcWidth")] HRESULT SrcWidth([out, retval] long *pVal);
    [propput, id(7), helpstring("property SrcWidth")] HRESULT SrcWidth([in] long newVal);
    [propget, id(8), helpstring("property SrcHeight")] HRESULT SrcHeight([out, retval] long *pVal);
    [propput, id(8), helpstring("property SrcHeight")] HRESULT SrcHeight([in] long newVal);
};

[
    object,
    uuid(4EE9EAD9-DA4D-43d0-9383-06B90C08B12B),
    dual,
    helpstring("IDxtAlphaSetter Interface"),
    pointer_default(unique)
]
interface IDxtAlphaSetter : IDXEffect
{
    // set the alpha to a particular number
    [propget, id(1), helpstring("property Alpha")] HRESULT Alpha([out, retval] long *pVal);
    [propput, id(1), helpstring("property Alpha")] HRESULT Alpha([in] long newVal);

    // set the alpha to a percentage of it's full value
    [propget, id(2), helpstring("property AlphaRamp")] HRESULT AlphaRamp([out, retval] double *pVal);
    [propput, id(2), helpstring("property AlphaRamp")] HRESULT AlphaRamp([in] double newVal);
};

// Supported by our JPEG DXT, that can do any wipe based on a bitmap
//

[
    object,
    uuid(DE75D011-7A65-11D2-8CEA-00A0C9441E20),
    dual,
    helpstring("IDxtJpeg Interface"),
    pointer_default(unique)
]
interface IDxtJpeg : IDXEffect
{
    [propget, id(1), helpstring("property MaskNum")] HRESULT MaskNum([out, retval] long *);
    [propput, id(1), helpstring("property MaskNum")] HRESULT MaskNum([in] long);
    [propget, id(2), helpstring("property MaskName")] HRESULT MaskName([out, retval] BSTR *pVal);
    [propput, id(2), helpstring("property MaskName")] HRESULT MaskName([in] BSTR newVal);
    [propget, id(3), helpstring("property ScaleX")] HRESULT ScaleX([out, retval] double *);
    [propput, id(3), helpstring("property ScaleX")] HRESULT ScaleX([in] double);
    [propget, id(4), helpstring("property ScaleY")] HRESULT ScaleY([out, retval] double *);
    [propput, id(4), helpstring("property ScaleY")] HRESULT ScaleY([in] double);
    [propget, id(5), helpstring("property OffsetX")] HRESULT OffsetX([out, retval] long *);
    [propput, id(5), helpstring("property OffsetX")] HRESULT OffsetX([in] long);
    [propget, id(6), helpstring("property OffsetY")] HRESULT OffsetY([out, retval] long *);
    [propput, id(6), helpstring("property OffsetY")] HRESULT OffsetY([in] long);
    [propget, id(7), helpstring("property ReplicateX")] HRESULT ReplicateX([out, retval] long *pVal);
    [propput, id(7), helpstring("property ReplicateX")] HRESULT ReplicateX([in] long newVal);
    [propget, id(8), helpstring("property ReplicateY")] HRESULT ReplicateY([out, retval] long *pVal);
    [propput, id(8), helpstring("property ReplicateY")] HRESULT ReplicateY([in] long newVal);
    [propget, id(9), helpstring("property BorderColor")] HRESULT BorderColor([out, retval] long *pVal);
    [propput, id(9), helpstring("property BorderColor")] HRESULT BorderColor([in] long newVal);
    [propget, id(10), helpstring("property BorderWidth")] HRESULT BorderWidth([out, retval] long *pVal);
    [propput, id(10), helpstring("property BorderWidth")] HRESULT BorderWidth([in] long newVal);
    [propget, id(11), helpstring("property BorderSoftness")] HRESULT BorderSoftness([out, retval] long *pVal);
    [propput, id(11), helpstring("property BorderSoftness")] HRESULT BorderSoftness([in] long newVal);
    HRESULT ApplyChanges();
    HRESULT LoadDefSettings();
};

    // key
    [
        object,
        uuid(3255de56-38fb-4901-b980-94b438010d7b),
        dual,
        helpstring("IDxtKey Interface"),
        pointer_default(unique)
    ]
    interface IDxtKey : IDXEffect
    {
        [propget, id(1), helpstring("property KeyType")]    HRESULT KeyType([out, retval] int *);
        [propput, id(1), helpstring("property Keytype")]    HRESULT KeyType([in] int);
        [propget, id(2), helpstring("property Hue")]   HRESULT Hue([out, retval] int *);
        [propput, id(2), helpstring("property Hue")]   HRESULT Hue([in] int );
        [propget, id(3), helpstring("property Luminance")]   HRESULT Luminance([out, retval] int *);
        [propput, id(3), helpstring("property Luminance")]   HRESULT Luminance([in] int );
        [propget, id(4), helpstring("property RGB")]    HRESULT RGB([out, retval] DWORD *);
        [propput, id(4), helpstring("property RGB")]    HRESULT RGB([in] DWORD );
        [propget, id(5), helpstring("property Similarity")]  HRESULT Similarity([out,retval] int * );
        [propput, id(5), helpstring("property Similarity")]  HRESULT Similarity([in] int );
        [propget, id(6), helpstring("property Invert")]    HRESULT Invert([out, retval] BOOL *);
        [propput, id(6), helpstring("property Invert")]    HRESULT Invert([in] BOOL);
    };

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // This little COM interface will look 'around' for the closest 
    // path match for a given file. If the file already exists, then
    // this interface should hardly do anything. If it's not found,
    // it will go look for it and if successful, return S_FALSE. If it
    // cannot find the file, it will call the hook, if set and return
    // it's return code. if the hook is not set, it is in a type of
    // error condition. The Dexter-provided MediaLocator will bring up
    // a dialog box asking you to browse for your file. Other COM
    // objects may do something else.
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(288581E0-66CE-11d2-918F-00C0DF10D434),
    odl,
    helpstring("IMediaLocator Interface"),
    pointer_default(unique)
]
interface IMediaLocator : IUnknown
{
    // same flags as used by IRenderEngine's SetSourceNameValidation
    HRESULT FindMediaFile( BSTR Input, BSTR FilterString, BSTR * pOutput, long Flags );
    HRESULT AddFoundLocation( BSTR DirectoryName );
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // This object provides caching of duration and stream type
    // information for files that would produce a directshow source
    // filter. It takes too long to figure this out in DShow right
    // now, so this is one way around it. The way it works is that
    // you first fill out the Filename property, then call and
    // ask how many streams it has, or, set the CurrentStream prop
    // and then ask for the per-stream properties, StreamType or
    // StreamLength. They both reference the CurrentStream prop that
    // you set. I also allowed you (for convenience) to just give
    // it a IUnknown Filter that represents an IBaseFilter source
    // filter that is NOT currently in a graph. It will use that
    // instead. When using this, though, you will not get cached
    // values. The cached values are stored in the system's ini file
    // called DCBC2A70-70D8-4459-BFFA-E0D61DEA3FDF.INI. Nice, huh? :-)
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(65BD0710-24D2-4ff7-9324-ED2E5D3ABAFA),
    odl,
    helpstring("IMediaDet Interface"),
    pointer_default(unique)
]
interface IMediaDet : IUnknown
{
    [propget, id(1), helpstring("property Filter")] HRESULT Filter([out, retval] IUnknown* *pVal);
    [propput, id(1), helpstring("property Filter")] HRESULT Filter([in] IUnknown* newVal);
    [propget, id(2), helpstring("property OutputStreams")] HRESULT OutputStreams([out, retval] long *pVal);
    [propget, id(3), helpstring("property CurrentStream")] HRESULT CurrentStream([out, retval] long *pVal);
    [propput, id(3), helpstring("property CurrentStream")] HRESULT CurrentStream([in] long newVal);
    [propget, id(4), helpstring("property StreamType")] HRESULT StreamType([out, retval] GUID *pVal);
    [propget, id(5), helpstring("property StreamTypeB")] HRESULT StreamTypeB([out, retval] BSTR *pVal);
    [propget, id(6), helpstring("property StreamLength")] HRESULT StreamLength([out, retval] double *pVal);
    [propget, id(7), helpstring("property Filename")] HRESULT Filename([out, retval] BSTR *pVal);
    [propput, id(7), helpstring("property Filename")] HRESULT Filename([in] BSTR newVal);
    [id(8), helpstring("method GetBitmapBits")] HRESULT GetBitmapBits(double StreamTime, long * pBufferSize, char * pBuffer, long Width, long Height);
    [id(9), helpstring("method WriteBitmapBits")] HRESULT WriteBitmapBits(double StreamTime, long Width, long Height, BSTR Filename );
    [propget, id(10), helpstring("property StreamMediaType")] HRESULT StreamMediaType([out, retval] AM_MEDIA_TYPE * pVal);
    [id(11), helpstring("method GetSampleGrabber")] HRESULT GetSampleGrabber( [out] ISampleGrabber ** ppVal );
    [propget, id(12), helpstring("property FrameRate")] HRESULT FrameRate([out, retval] double *pVal);
    [id(13), helpstring("method EnterBitmapGrabMode")] HRESULT EnterBitmapGrabMode( double SeekTime  );
};


// useless interface, don't use it!

[
    object,
    uuid(AE9472BE-B0C3-11D2-8D24-00A0C9441E20),
    odl,
    helpstring("IGrfCache Interface"),
    pointer_default(unique)
]
interface IGrfCache : IDispatch
{
    [id(1), helpstring("method AddFilter")] 
    HRESULT AddFilter(
        IGrfCache * ChainedCache,
        LONGLONG ID, 
        const IBaseFilter * pFilter, 
        LPCWSTR pName);

    [id(2), helpstring("method ConnectPins")] 
    HRESULT ConnectPins(
        IGrfCache * ChainedCache,
        LONGLONG PinID1, 
        const IPin * pPin1, 
        LONGLONG PinID2, 
        const IPin * pPin2);

    [id(3), helpstring("method SetGraph")] 
    HRESULT SetGraph(const IGraphBuilder * pGraph);

    [id(4), helpstring("method DoConnectionsNow")] 
    HRESULT DoConnectionsNow();
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // The RenderEngin builds a graph from the timeline and gives
    // you some simple positional commands.
    // explained methods:
    // SetTimelineObject - tell the render engine who to parse
    // ConnectEverything - build up a graph based on the timeline
    // ScrapIt - throw away graph and everything
    // GetFilterGraph - get the graph that's built up, if any
    // SetFilterGraph - allows you to preset the graph that's built up.
    //      cannot call this if there already is a graph.

    // !!! the following methods are unused/not implemented

    // SetInterestRange - discard COM objects and memory outside of this
    //      range, if possible. Used for scrubbing on a long timeline and
    //      freeing up resources
    // SetRenderRange - pretend like a portion of the timeline IS the timeline
    //      and don't connect anything in the graph outside of that range.
    // Commit - allocate what's necessary and get prepared to run
    // Decommit - free anything possible
    // GetCaps - find out some info about the render engine
    // DoSmartRecompression - connect compressed sources if 
    //      possible
    // in the graph, this will RenderPin( ) on every switcher 
    //      rendering pin.
    // SetSourceNameValidation - allows you to set some flags which
    // determine how source files are found, if they need to be found.
    //      FilterString is a list of extensions to find for the media
    //      files (see OPENFILENAME filters)
    //      pOverride is a media locator you would like to use instead
    //      of the built in one
    //      The flags are defined in the struct immediately below.
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(6BEE3A81-66C9-11d2-918F-00C0DF10D434),
    odl,
    helpstring("IRenderEngine Interface"),
    pointer_default(unique)
]
interface IRenderEngine : IUnknown
{
    HRESULT SetTimelineObject( IAMTimeline * pTimeline );
    HRESULT GetTimelineObject( [out] IAMTimeline ** ppTimeline );
    HRESULT GetFilterGraph( [out] IGraphBuilder ** ppFG );
    HRESULT SetFilterGraph( IGraphBuilder * pFG );
    HRESULT SetInterestRange( REFERENCE_TIME Start, REFERENCE_TIME Stop );
    HRESULT SetInterestRange2( double Start, double Stop );
    HRESULT SetRenderRange( REFERENCE_TIME Start, REFERENCE_TIME Stop );
    HRESULT SetRenderRange2( double Start, double Stop );
    HRESULT GetGroupOutputPin( long Group, [out] IPin ** ppRenderPin );
    HRESULT ScrapIt( );
    HRESULT RenderOutputPins( );
    HRESULT GetVendorString( [out,retval] BSTR * pVendorID );
    HRESULT ConnectFrontEnd( );
    HRESULT SetSourceConnectCallback( IGrfCache * pCallback );
    HRESULT SetDynamicReconnectLevel( long Level );
    HRESULT DoSmartRecompression( );
    HRESULT UseInSmartRecompressionGraph( );

    HRESULT SetSourceNameValidation( BSTR FilterString, IMediaLocator * pOverride, LONG Flags );

    // not implemented yet
    HRESULT Commit( );
    HRESULT Decommit( );
    HRESULT GetCaps( long Index, long * pReturn );
};

[
    object,
    uuid(6BEE3A82-66C9-11d2-918F-00C0DF10D434),
    odl,
    helpstring("IRenderEngine2 Interface"),
    pointer_default(unique)
]
interface IRenderEngine2 : IUnknown
{
    HRESULT SetResizerGUID( GUID ResizerGuid );
}

// used for the smart render engine when it needs to find a compressor
[
    object,
    uuid(F03FA8DE-879A-4d59-9B2C-26BB1CF83461),
    odl,
    helpstring("IFindCompressorCB Interface"),
    pointer_default(unique)
]
interface IFindCompressorCB : IUnknown
{
    HRESULT GetCompressor( AM_MEDIA_TYPE * pType, AM_MEDIA_TYPE * pCompType, [out] IBaseFilter ** ppFilter );
}

[
    object,
    uuid(F03FA8CE-879A-4d59-9B2C-26BB1CF83461),
    odl,
    helpstring("ISmartRenderEngine Interface"),
    pointer_default(unique)
]
interface ISmartRenderEngine : IUnknown
{
    HRESULT SetGroupCompressor( long Group, IBaseFilter * pCompressor );
    HRESULT GetGroupCompressor( long Group, IBaseFilter ** pCompressor );
    HRESULT SetFindCompressorCB( IFindCompressorCB * pCallback );
}                  

////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////
// TIMELINE TIMELINE TIMELINE TIMELINE TIMELINE TIMELINE
////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Every object on the timeline supports at least this interface.
    // explained methods:
    // Get/SetStartStop - the timeline times at which this object is
    //      active. Groups and Tracks have start times of zero.
    // FixTimes - used by the render engine. Rounds the input times
    //      to the nearest FPS of the parent Group, for use in setting
    //      up the big switch.
    // GetSubObject - get the sub-object which is associated with this
    //      timeline object. Each timeline object can carry around a
    //      pointer to 'something else'. For our Render Engine, this is
    //      a pointer to a filter that gets put into a graph. 
    // NOTE: Getting the subobject will FORCE it to load if it's possible
    //      to force this. If you don't want it to do this, don't call
    //      this function.
    // SetSubObject - see GetSubObject
    // SetSubObjectGUID - instead of giving the node a pointer, you can
    //      instead give it a GUID and see if this works instead. The
    //      sub-object will attempt to be instantiated when 'necessary'
    //      which is really when it's asked for with GetSubObject./
    //      !!! a better way to do this perhaps?
    // GetSubObjectLoaded - ask if the sub-object pointer is set
    // Get/SetTimelineType - return the major type which is stored here,
    //      used by the API user and the render engine.
    // Get/SetTimelineSubType - see above
    // Get/SetUserID - get and set a number, any number
    // GetGenID - every created object has a unique number to it. Used
    //      by the render engine.
    // Get/SetUserName - a storable name, for users of the API
    // Get/SetPropertySetter - the object that will set properties for this
    //      object (it will support IPropertySetter and it is created by 
    //      CPropertySetter)
    // Get/SetUserData - gets the persistant data used by the user of
    //      the API.
    // Get/SetMuted - set whether this object should be active or not.
    //      Setting a parent of other objects off also turns off the
    //      sub-objects.
    // Get/SetLocked - set whether you can edit this object or not.
    //      Note: the timeline doesn't enforce this, it just stores
    //      a value for convenience.
    // Get/SetDirtyRange - 
    // RemoveAll - remove this object, and if in the tree already, all it's
    //        sub objects, including children
    // Remove - remove this object, and if in the tree already, all it's
    //        sub objects, but not kids
    // GetTimelineNoRef - called internally by the timeline.
    // GetGroupIBelongTo - called internally by the timeline.
    // GetEmbedDepth - find out how many tracks we are a part of
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    local,
    uuid(78530B77-61F9-11D2-8CAD-00A024580902),
    odl,
    helpstring("IAMTimelineObj Interface"),
    pointer_default(unique)
]
interface IAMTimelineObj : IUnknown
{
    [helpstring("method GetStartStop")] 
    HRESULT GetStartStop(REFERENCE_TIME * pStart, REFERENCE_TIME * pStop);
    [helpstring("method GetStartStop2")] 
    HRESULT GetStartStop2(REFTIME * pStart, REFTIME * pStop);
    [helpstring("method FixTimes")] 
    HRESULT FixTimes(REFERENCE_TIME * pStart, REFERENCE_TIME * pStop);
    [helpstring("method FixTimes2")] 
    HRESULT FixTimes2(REFTIME * pStart, REFTIME * pStop);
    [helpstring("method SetStartStop")] 
    HRESULT SetStartStop(REFERENCE_TIME Start, REFERENCE_TIME Stop);
    [helpstring("method SetStartStop2")] 
    HRESULT SetStartStop2(REFTIME Start, REFTIME Stop);
    [helpstring("method GetPropertySetter")] 
    HRESULT GetPropertySetter([out,retval] IPropertySetter* *pVal);
    [helpstring("method SetPropertySetter")] 
    HRESULT SetPropertySetter(IPropertySetter* newVal);
    [helpstring("method GetSubObject")] 
    HRESULT GetSubObject([out,retval] IUnknown* *pVal);
    [helpstring("method SetSubObject")] 
    HRESULT SetSubObject(IUnknown* newVal);
    [helpstring("method SetSubObjectGUID")] 
    HRESULT SetSubObjectGUID(GUID newVal);
    [helpstring("method SetSubObjectGUIDByBSTR")] 
    HRESULT SetSubObjectGUIDB(BSTR newVal);
    [helpstring("method GetSubObjectGUID")] 
    HRESULT GetSubObjectGUID(GUID * pVal);
    [helpstring("method GetSubObjectGUIDByBSTR")] 
    HRESULT GetSubObjectGUIDB([out,retval] BSTR * pVal);
    [helpstring("method GetSubObjectLoaded")] 
    HRESULT GetSubObjectLoaded(BOOL * pVal);
    [helpstring("method GetTimelineType")] 
    HRESULT GetTimelineType(TIMELINE_MAJOR_TYPE * pVal);
    [helpstring("method SetTimelineType")] 
    HRESULT SetTimelineType(TIMELINE_MAJOR_TYPE newVal);
    [helpstring("method GetUserID")] 
    HRESULT GetUserID(long * pVal);
    [helpstring("method SetUserID")] 
    HRESULT SetUserID(long newVal);
    [helpstring("method GetGenID")] 
    HRESULT GetGenID( long * pVal );
    [helpstring("method GetUserName")] 
    HRESULT GetUserName([out,retval] BSTR * pVal);
    [helpstring("method SetUserName")] 
    HRESULT SetUserName(BSTR newVal);
    [helpstring("method GetUserData")] 
    HRESULT GetUserData(BYTE * pData, long * pSize);
    [helpstring("method SetUserData")] 
    HRESULT SetUserData(BYTE * pData, long Size);
    [helpstring("method GetMuted")] 
    HRESULT GetMuted(BOOL * pVal);
    [helpstring("method SetMuted")] 
    HRESULT SetMuted(BOOL newVal);
    [helpstring("method GetLocked")] 
    HRESULT GetLocked(BOOL * pVal);
    [helpstring("method SetLocked")] 
    HRESULT SetLocked(BOOL newVal);
    [helpstring("method GetDirtyRange")] 
    HRESULT GetDirtyRange(REFERENCE_TIME * pStart, REFERENCE_TIME * pStop);
    [helpstring("method GetDirtyRange")] 
    HRESULT GetDirtyRange2(REFTIME * pStart, REFTIME * pStop);
    [helpstring("method SetDirtyRange")] 
    HRESULT SetDirtyRange(REFERENCE_TIME Start, REFERENCE_TIME Stop);
    [helpstring("method SetDirtyRange")] 
    HRESULT SetDirtyRange2(REFTIME Start, REFTIME Stop);
    [helpstring("method ClearDirty")] 
    HRESULT ClearDirty( );
    [helpstring("method Remove")] 
    HRESULT Remove();
    [helpstring("method RemoveAll")] 
    HRESULT RemoveAll();
    HRESULT GetTimelineNoRef( IAMTimeline ** ppResult );
    HRESULT GetGroupIBelongTo( [out] IAMTimelineGroup ** ppGroup );
    HRESULT GetEmbedDepth( long * pVal );
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Any object on the timeline that can have an effect put on it 
    // implements this interface. This includes sources, tracks, and
    // compositions.
    // explained methods:
    // EffectInsBefore - insert an effect at the given priority onto
    //      this object. The effect's times will be clipped within
    //      this object's bounds. Use -1 to specify 'at the end' for priority.
    //      You cannot have two effects at the same priority.
    // EffectSwapPriorities - swaparoo two effects. Makes undo easier to
    //      implement.
    // EffectGetCount - get how many effects are applied to this object.
    // GetEffect - get the nth effect applied to this object
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

[
    object,
    uuid(EAE58537-622E-11d2-8CAD-00A024580902),
    odl,
    helpstring("IAMTimelineEffectable Interface"),
    pointer_default(unique)
]
interface IAMTimelineEffectable : IUnknown
{
    [helpstring("method EffectInsBefore")] 
    HRESULT EffectInsBefore(IAMTimelineObj * pFX, long priority);
    [helpstring("method EffectSwapPriorities")] 
    HRESULT EffectSwapPriorities(long PriorityA, long PriorityB);
    [helpstring("method EffectGetCount")] 
    HRESULT EffectGetCount(long * pCount);
    [helpstring("method GetEffect")] 
    HRESULT GetEffect([out] IAMTimelineObj ** ppFx, long Which);
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Any effect on the timeline will support at least this interface.
    // NOTE: The Start/Stop times on this object are RELATIVE to their
    // parent's, as are all start/stop times.
    // explained methods:
    // EffectGetPriority - finds out this effect's priority related to the others.
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(BCE0C264-622D-11d2-8CAD-00A024580902),
    odl,
    helpstring("IAMTimelineEffect Interface"),
    pointer_default(unique)
]
interface IAMTimelineEffect : IUnknown
{
    [helpstring("method EffectGetPriority")] 
    HRESULT EffectGetPriority(long * pVal);
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Any object on the timeline that can have a transition put on it
    // implements this interface
    // explained methods:
    // TransAdd - add a transition on this object. Multiple trans's on 
    //      the same object cannot overlap in time. Transitions' times
    //      must lie within the bounds of their parent.
    // TransGetCount - get how many transitions are applied to this
    //      object.
    // GetNextTrans - given a time, get the next transition that happens
    //      on this object after that time. On exit, the input time is
    //      set to the start time of the transition.
    // GetTransAtTime - find a transition forwards or backwards from
    //        a given spot. See DEXTERF_TRACK_SEARCH_FLAGS enum.
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(378FA386-622E-11d2-8CAD-00A024580902),
    odl,
    helpstring("IAMTimelineTransable Interface"),
    pointer_default(unique)
]
interface IAMTimelineTransable : IUnknown
{
    [helpstring("method TransAdd")] 
    HRESULT TransAdd(IAMTimelineObj * pTrans);
    [helpstring("method TransGetCount")] 
    HRESULT TransGetCount(long * pCount);
    [helpstring("method GetNextTrans")] 
    HRESULT GetNextTrans([out] IAMTimelineObj ** ppTrans, REFERENCE_TIME * pInOut);
    [helpstring("method GetNextTrans2")] 
    HRESULT GetNextTrans2([out] IAMTimelineObj ** ppTrans, REFTIME * pInOut);
    [helpstring("method GetTransAtTime")] 
    HRESULT GetTransAtTime(
        [out] IAMTimelineObj ** ppObj, 
        REFERENCE_TIME Time, 
        long SearchDirection ); 
    [helpstring("method GetTransAtTime2")] 
    HRESULT GetTransAtTime2([out] IAMTimelineObj ** ppObj, REFTIME Time, long SearchDirection ); 
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Any object on the timeline that can be split into two will
    // implement this interface. Namely, source, effects, and transitions
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(A0F840A0-D590-11d2-8D55-00A0C9441E20),
    odl,
    helpstring("IAMTimelineSplittable Interface"),
    pointer_default(unique)
]
interface IAMTimelineSplittable : IUnknown
{
    HRESULT SplitAt(REFERENCE_TIME Time);
    HRESULT SplitAt2(REFTIME Time);
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Any trans on the timeline will support at least this interface.
    // NOTE: The Start/Stop times on this object are RELATIVE to their
    // parent's, as are all start/stop times.
    // explained methods:
    // GetCutPoint - get where this transition should cut from A to B
    //      if the transition were not applied.
    // GetA2B - get if this transition is to go from A->B or B->A.
    // GetBackwards - get if this transition should run backwards.
    // GetCutsOnly - force no transition, force doing a cut
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(BCE0C265-622D-11d2-8CAD-00A024580902),
    odl,
    helpstring("IAMTimelineTrans Interface"),
    pointer_default(unique)
]
interface IAMTimelineTrans : IUnknown
{
    [helpstring("method GetCutPoint")] 
    HRESULT GetCutPoint(REFERENCE_TIME * pTLTime);
    [helpstring("method GetCutPoint2")] 
    HRESULT GetCutPoint2(REFTIME * pTLTime);
    [helpstring("method SetCutPoint")] 
    HRESULT SetCutPoint(REFERENCE_TIME TLTime);
    [helpstring("method SetCutPoint2")]
    HRESULT SetCutPoint2(REFTIME TLTime);
    [helpstring("method GetSwapInputs")] 
    HRESULT GetSwapInputs( BOOL * pVal );
    [helpstring("method SetSwapInputs")] 
    HRESULT SetSwapInputs( BOOL pVal );
    [helpstring("method GetCutsOnly")] 
    HRESULT GetCutsOnly( BOOL * pVal );
    [helpstring("method SetCutsOnly")] 
    HRESULT SetCutsOnly( BOOL pVal );
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Sources represent any source media object on the timeline.
    // They extend an IAMTimelineObj to include media start and stop
    // times, a media name (which could represent darned near anything),
    // and a StreamNumber, which defines which stream out of a potential
    // many this stream represents from a source clip.
    // explained methods:
    // ModifyStopTime - like calling SetStartStop, but this method just
    //      adjusts the tail end of the clip.
    // FixMediaTimes - called by the render engine to round times to
    //      this source clip's parent group's FPS.
    // SpliceWithNext - if the next clip after this is the same source
    //      and this's stop time matches next's start time, the two
    //      will be joined.
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(78530B79-61F9-11D2-8CAD-00A024580902),
    odl,
    helpstring("IAMTimelineSrc Interface"),
    pointer_default(unique)
]
interface IAMTimelineSrc : IUnknown
{
    [helpstring("method GetMediaTimes")] 
    HRESULT GetMediaTimes(REFERENCE_TIME * pStart, REFERENCE_TIME * pStop);
    [helpstring("method GetMediaTimes2")] 
    HRESULT GetMediaTimes2(REFTIME * pStart, REFTIME * pStop);
    [helpstring("method ModifyStopTime")] 
    HRESULT ModifyStopTime(REFERENCE_TIME Stop);
    [helpstring("method ModifyStopTime2")] 
    HRESULT ModifyStopTime2(REFTIME Stop);
    [helpstring("method FixMediaTimes")] 
    HRESULT FixMediaTimes(REFERENCE_TIME * pStart, REFERENCE_TIME * pStop);
    [helpstring("method FixMediaTimes2")] 
    HRESULT FixMediaTimes2(REFTIME * pStart, REFTIME * pStop);
    [helpstring("method SetMediaTimes")] 
    HRESULT SetMediaTimes(REFERENCE_TIME Start, REFERENCE_TIME Stop);
    [helpstring("method SetMediaTimes2")] 
    HRESULT SetMediaTimes2(REFTIME Start, REFTIME Stop);
    [helpstring("method SetMediaLength")] 
    HRESULT SetMediaLength(REFERENCE_TIME Length);
    [helpstring("method SetMediaLength2")] 
    HRESULT SetMediaLength2(REFTIME Length);
    [helpstring("method GetMediaLength")] 
    HRESULT GetMediaLength(REFERENCE_TIME * pLength);
    [helpstring("method GetMediaLength2")] 
    HRESULT GetMediaLength2(REFTIME * pLength);
    [helpstring("method GetMediaName")] 
    HRESULT GetMediaName([out,retval] BSTR * pVal);
    [helpstring("method SetMediaName")] 
    HRESULT SetMediaName(BSTR newVal);
    [helpstring("method SpliceWithNext")] 
    HRESULT SpliceWithNext(IAMTimelineObj * pNext);
    [helpstring("method GetStreamNumber")] 
    HRESULT GetStreamNumber(long * pVal);
    [helpstring("method SetStreamNumber")] 
    HRESULT SetStreamNumber(long Val);
    HRESULT IsNormalRate( BOOL * pVal );

    // If a source can't figure out its frames per second, this number
    // will be used (eg: Dib sequences).  AVI, MPEG, etc. will not need this
    // Use 0 fps to prevent a filename like "ski4.jpg" from using a dib seq
    [helpstring("method GetDefaultFPS")] 
    HRESULT GetDefaultFPS(double * pFPS);
    [helpstring("method SetDefaultFPS")] 
    HRESULT SetDefaultFPS(double FPS);

    // !!! This is video specific.. new interface?
    // what kind of stretching? Stretch, crop, or preserve aspect ratio?
    [helpstring("method GetStretchMode")] 
    HRESULT GetStretchMode(int * pnStretchMode);
    [helpstring("method SetStretchMode")] 
    HRESULT SetStretchMode(int nStretchMode);
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Tracks are things that can contain media in them. You can add
    // and remove sources, effects, and transitions from them. Sources
    // are added according to the current insert mode of the timeline.
    // If in OVERLAY mode, moving or adding a source to a time that's
    // already occupied by another source will wipe out any overlapping
    // portion of the underlying source. In InsertMode, everything at
    // the insert point is moved down in time to make room for the
    // new source.
    // explained methods:
    // SrcAdd - add the source to this track. The source's start/stop
    //      times must be set up first.
    // GetNextSrc - pass a time in at which you wish to find a source
    //      and it will return the first source which occurs after the 
    //      given time.
    // MoveEverythingBy - bump a bunch of objects a certain direction
    //      on the track by a given time.
    // GetSourcesCount - how many sources are on this track?
    // AreYouBlank - do you contain anything at all?
    // GetSrcAtTime - find a source at a given time. SearchDirection
    //      is which way to search. -1 = backwards, 1 = forwards
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(EAE58538-622E-11d2-8CAD-00A024580902),
    odl,
    helpstring("IAMTimelineTrack Interface"),
    pointer_default(unique)
]
interface IAMTimelineTrack : IUnknown
{
    [helpstring("method SrcAdd")] 
    HRESULT SrcAdd(IAMTimelineObj * pSource);
    [helpstring("method GetNextSrc")] 
    HRESULT GetNextSrc([out] IAMTimelineObj ** ppSrc, REFERENCE_TIME * pInOut);
    [helpstring("method GetNextSrc2")] 
    HRESULT GetNextSrc2([out] IAMTimelineObj ** ppSrc, REFTIME * pInOut);
    [helpstring("method MoveEverythingBy")] 
    HRESULT MoveEverythingBy( REFERENCE_TIME Start, REFERENCE_TIME MoveBy );
    [helpstring("method MoveEverythingBy2")] 
    HRESULT MoveEverythingBy2( REFTIME Start, REFTIME MoveBy );
    [helpstring("method GetSourcesCount")] 
    HRESULT GetSourcesCount( long * pVal );
    [helpstring("method AreYouBlank")] 
    HRESULT AreYouBlank( long * pVal );
    [helpstring("method GetSrcAtTime")] 
    HRESULT GetSrcAtTime(
        [out] IAMTimelineObj ** ppSrc, 
        REFERENCE_TIME Time, 
        long SearchDirection ); 
    [helpstring("method GetSrcAtTime2")] 
    HRESULT GetSrcAtTime2([out] IAMTimelineObj ** ppSrc, REFTIME Time, long SearchDirection ); 
    HRESULT InsertSpace( REFERENCE_TIME rtStart, REFERENCE_TIME rtEnd );
    HRESULT InsertSpace2( REFTIME rtStart, REFTIME rtEnd );
    HRESULT ZeroBetween( REFERENCE_TIME rtStart, REFERENCE_TIME rtEnd );
    HRESULT ZeroBetween2( REFTIME rtStart, REFTIME rtEnd );
    HRESULT GetNextSrcEx(IAMTimelineObj * pLast, [out] IAMTimelineObj **ppNext);
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // This virtual track interface is shared by both the compositions
    // and tracks (and groups). 
    // explained methods:
    // TrackGetPriority - used by rendering objects which need to know this.
    // SetTrackDirty - !!! not sure if this is useful.
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(A8ED5F80-C2C7-11d2-8D39-00A0C9441E20),
    odl,
    helpstring("IAMTimelineVirtualTrack Interface"),
    pointer_default(unique)
]
interface IAMTimelineVirtualTrack : IUnknown
{
    [helpstring("method TrackGetPriority")] 
    HRESULT TrackGetPriority(long * pPriority);
    [helpstring("method SetTrackDirty")] 
    HRESULT SetTrackDirty( );
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Compositions are like tracks in the sense that they also
    // implement IAMVirtualTrack and you can put transitions and effects
    // on them, but they really are the SUM of those tracks that they
    // contain. They are "embedded" compositions. They should only contain
    // media of one particular type (like all video or all audio), but 
    // this is not enforced. You can add a composition to another
    // composition with VTrackInsBefore, just like you can add a track.
    // The very top composition to which all other comps and tracks belong
    // is a Group, which supports I-AMTimelineGroup as well as I-AMTimelineComp.
    // explained methods:
    // VTrackInsBefore - does NOT mean VideoTrack. Means Virtual Track.
    //      Adds a virtual track to a composition at a given priority.
    //      use -1 to mean "at the end"
    // VTrackSwapPriorities - switch two vtracks around.
    // VTrackGetCount - get how many vtracks this comp contains.
    // GetVTrack - you get the idea
    // GetCountOfType - Get the total number of these objects this comp
    //      and all it's vtracks (recursively) contains. !!! this may be dead.
    // GetRecursiveLayerOfType - given a number, returns a given track. This
    //      is done recursively. You need to pass in a pointer to the number,
    //        and it will be modified upon exit to an unknown value. DO NOT
    //      CALL THE VERSION WITH THE POINTER!
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(EAE58536-622E-11d2-8CAD-00A024580902),
    odl,
    helpstring("IAMTimelineComp Interface"),
    pointer_default(unique)
]
interface IAMTimelineComp : IUnknown
{
    [helpstring("method VTrackInsBefore")] 
    HRESULT VTrackInsBefore(IAMTimelineObj * pVirtualTrack, long Priority);
    [helpstring("method VTrackSwapPriorities")] 
    HRESULT VTrackSwapPriorities(long VirtualTrackA, long VirtualTrackB);
    [helpstring("method VTrackGetCount")] 
    HRESULT VTrackGetCount(long * pVal);
    [helpstring("method GetVTrack")] 
    HRESULT GetVTrack([out] IAMTimelineObj ** ppVirtualTrack, long Which);
    [helpstring("method GetCountOfType")] 
    HRESULT GetCountOfType(long * pVal, long * pValWithComps, TIMELINE_MAJOR_TYPE MajorType );
    [helpstring("method GetRecursiveLayerOfType")] 
    HRESULT GetRecursiveLayerOfType(
        [out] IAMTimelineObj ** ppVirtualTrack, 
        long WhichLayer, 
        TIMELINE_MAJOR_TYPE Type);
    [helpstring("method GetRecursiveLayerOfTypeI (do not call)")] 
    HRESULT GetRecursiveLayerOfTypeI(
        [out] IAMTimelineObj ** ppVirtualTrack, 
        [in,out] long * pWhichLayer, 
        TIMELINE_MAJOR_TYPE Type);
    HRESULT GetNextVTrack(IAMTimelineObj *pVirtualTrack, [out] IAMTimelineObj **ppNextVirtualTrack);
};

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // Groups represent the topmost composition in a timeline. Every
    // group should contain media of only one major type (like all video).
    // The timeline can contain multiple groups, see it's interface for
    // this. Each group has a particular "media type" that you can get/set
    // which help identify it. Each group has an associated FPS which
    // is used by the render engine in setting up the big switch. All
    // cuts on the timeline will happen rounded to this nearest FPS for
    // this particular group. Each group has a priority which enables
    // writing out multiple-stream files with 1 or more streams of the
    // same type. (Like a 2 video stream AVI file).
    // explained methods:
    // SetTimeline - this is called internally when the group is added.
    //      Do not call this.
    // GetTimeline - get the timeline this group belongs to.
    // GetPriority - get this group's priority
    // Get/SetOutputFPS - explained above
    // SetMediaTypeForVB - method for VB. Pass in 0 for video, 1 for audio
    // SetRecompFormatFromSource - set the recompress format based on the
    //  source that's loaded or set in the IAMTimelineSrc
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(9EED4F00-B8A6-11d2-8023-00C0DF10D434),
    odl,
    helpstring("IAMTimelineGroup Interface"),
    pointer_default(unique)
]
interface IAMTimelineGroup : IUnknown
{
    [helpstring("method SetTimeline")] 
    HRESULT SetTimeline( IAMTimeline * pTimeline );
    [helpstring("method GetTimeline")] 
    HRESULT GetTimeline( [out] IAMTimeline ** ppTimeline );
    [helpstring("method GetPriority")] 
    HRESULT GetPriority( long * pPriority );
    [helpstring("method GetMediaType")] 
    HRESULT GetMediaType([out] AM_MEDIA_TYPE *);
    [helpstring("method SetMediaType")] 
    HRESULT SetMediaType([in] AM_MEDIA_TYPE *);
    [helpstring("method SetOutputFPS")] 
    HRESULT SetOutputFPS(double FPS);
    [helpstring("method GetOutputFPS")] 
    HRESULT GetOutputFPS(double * pFPS);
    [helpstring("method SetGroupName")] 
    HRESULT SetGroupName( BSTR pGroupName );
    [helpstring("method GetGroupName")] 
    HRESULT GetGroupName( [out,retval] BSTR * pGroupName );
    // in preview mode, skip frames.  In authoring mode, don't
    [helpstring("method SetPreviewMode")] 
    HRESULT SetPreviewMode( BOOL fPreview );
    [helpstring("method GetPreviewMode")] 
    HRESULT GetPreviewMode( BOOL *pfPreview );
    [helpstring("method SetMediaTypeForVB")] 
    HRESULT SetMediaTypeForVB([in] long Val );
    // how many frames ahead switch can run
    [helpstring("method GetOutputBuffering")] 
    HRESULT GetOutputBuffering([out] int *pnBuffer );
    [helpstring("method SetOutputBuffering")] 
    HRESULT SetOutputBuffering([in] int nBuffer );

    HRESULT SetSmartRecompressFormat( long * pFormat );
    HRESULT GetSmartRecompressFormat( long ** ppFormat );
    HRESULT IsSmartRecompressFormatSet( BOOL * pVal );
    HRESULT IsRecompressFormatDirty( BOOL * pVal );
    HRESULT ClearRecompressFormatDirty( );
    HRESULT SetRecompFormatFromSource( IAMTimelineSrc * pSource );
};


    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // The main timeline. This is the base object you use to set
    // properties of the timeline as a whole, and to create blank
    // objects for use within the timeline. You cannot create the
    // objects using COM methods, you must go through the timeline to
    // create this. That's because certain information is set before
    // handing the object back to you. Every object created by the
    // timeline will support at LEAST IAMTimelineObj. For any timeline,
    // it can have one or more "groups" that it knows about. Each group
    // has the capability to hold a complete sub-tree containing media
    // that is all of one type. This logical seperation is used for the
    // rendering engine, but is not strictly enforced.
    // explained methods:
    // CreateEmptyNode - pass in a mid type and it will pass back
    //      an object of the type you requested.
    // AddGroup - add a created group to the tree
    // RemGroupFromList - make sure timeline no longer knows about this group.
    //        does NOT do anything to the group itself. Normally the user
    //        does not want to call this, it's called from the Group's Remove( ) method.
    // GetGroup - get a certain group
    // GetGroupCount - get how many groups
    // ClearAllGroups - clear everything
    // GetInsertMode - ask what the insert mode is, overlay or insert
    // SetInsertMode - set whether to insert or overlay
    // EnableTransitions - turn transitions on or off as a whole
    // EnableEffects - same deal.
    // SetIntererstRange - discard sub-objects outside of a given
    //      time range, to save memory/resources
    // Get/SetDefaultFPS - set the 'default' FPS for this timeline,
    //      the RenderEngine reads this information for setting itself up
    //      by default.
    // GetCountOfType - ask for how many of a given thing are in a given
    //      group. !!! this may be a useless function.
    // !!! not implemented
    // IsDirty - asks if anything in the timeline needs to be redrawn
    // GetDirtyRange - same deal
    // ValidateSourceNames - make sure the filenames in the sources
    //      really exist. Use the same enum flags as the render engine
    //      uses for SetSourceNameValidation. Source's filenames will be
    //      changed to those of the found ones in the timeline.
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

[
    object,
    uuid(78530B74-61F9-11D2-8CAD-00A024580902),
    odl,
    helpstring("IAMTimeline Interface"),
    pointer_default(unique)
]
interface IAMTimeline : IUnknown
{
    [helpstring("method CreateEmptyNode")] 
    HRESULT CreateEmptyNode([out] IAMTimelineObj ** ppObj, TIMELINE_MAJOR_TYPE Type );
    HRESULT AddGroup( IAMTimelineObj * pGroup );
    HRESULT RemGroupFromList( IAMTimelineObj * pGroup );
    HRESULT GetGroup( [out] IAMTimelineObj ** ppGroup, long WhichGroup );
    HRESULT GetGroupCount( long * pCount );
    HRESULT ClearAllGroups( );
    HRESULT GetInsertMode( long * pMode );
    [helpstring("method SetInsertMode")] 
    HRESULT SetInsertMode(long Mode);
    [helpstring("method EnableTransitions")] 
    HRESULT EnableTransitions(BOOL fEnabled);
    [helpstring("method TransitionsEnabled")] 
    HRESULT TransitionsEnabled(BOOL * pfEnabled);
    [helpstring("method EnableEffects")] 
    HRESULT EnableEffects(BOOL fEnabled);
    [helpstring("method EffectsEnabled")] 
    HRESULT EffectsEnabled(BOOL * pfEnabled);
    [helpstring("method SetInterestRange")] 
    HRESULT SetInterestRange(REFERENCE_TIME Start, REFERENCE_TIME Stop);
    [helpstring("method GetDuration")] 
    HRESULT GetDuration(REFERENCE_TIME * pDuration);
    [helpstring("method GetDuration2")] 
    HRESULT GetDuration2(double * pDuration);
    [helpstring("method SetDefaultFPS")] 
    HRESULT SetDefaultFPS(double FPS);
    [helpstring("method GetDefaultFPS")] 
    HRESULT GetDefaultFPS(double * pFPS);
    [helpstring("method IsDirty")] 
    HRESULT IsDirty(BOOL * pDirty);
    [helpstring("method GetDirtyRange")] 
    HRESULT GetDirtyRange(REFERENCE_TIME * pStart, REFERENCE_TIME * pStop);
    [helpstring("method GetCountOfType")] 
    HRESULT GetCountOfType(long Group, long * pVal, long * pValWithComps, TIMELINE_MAJOR_TYPE MajorType );
    HRESULT ValidateSourceNames( long ValidateFlags, IMediaLocator * pOverride, LONG_PTR NotifyEventHandle );

    HRESULT SetDefaultTransition( GUID * pGuid );
    HRESULT GetDefaultTransition( GUID * pGuid );
    HRESULT SetDefaultEffect( GUID * pGuid );
    HRESULT GetDefaultEffect( GUID * pGuid );
    HRESULT SetDefaultTransitionB( BSTR pGuid );
    HRESULT GetDefaultTransitionB( [out,retval] BSTR * pGuid );
    HRESULT SetDefaultEffectB( BSTR pGuid );
    HRESULT GetDefaultEffectB( [out,retval] BSTR * pGuid );
};

////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////
// XML STUFF --- XML STUFF --- XML STUFF --- XML STUFF --- XML
////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////

//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// Xml2Dex - converts back and forth between XML and a dexter project
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

[
    object,
    uuid(18C628ED-962A-11D2-8D08-00A0C9441E20),
    odl,
    helpstring("IXml2Dex Interface"),
    pointer_default(unique)
]
interface IXml2Dex : IDispatch
{
    [id(1), helpstring("method CreateGraphFromFile")] 
    HRESULT CreateGraphFromFile([out] IUnknown ** ppGraph, IUnknown * pTimeline, BSTR Filename);
    [id(2), helpstring("method WriteGrfFile")] 
    HRESULT WriteGrfFile(IUnknown * pGraph, BSTR FileName);
    [id(3), helpstring("method WriteXMLFile")] 
    HRESULT WriteXMLFile(IUnknown * pTimeline, BSTR FileName);
    [id(5), helpstring("method ReadXMLFile")] 
    HRESULT ReadXMLFile(IUnknown *pTimeline, BSTR XMLName);
    [id(6), helpstring("method Delete")] 
    HRESULT Delete(IUnknown *pTimeline, double dStart, double dEnd);
    [id(7), helpstring("method WriteXMLPart")] 
    HRESULT WriteXMLPart(IUnknown * pTimeline, double dStart, double dEnd, BSTR FileName);
    [id(8), helpstring("method PasteXMLFile")] 
    HRESULT PasteXMLFile(IUnknown * pTimeline, double dStart, BSTR FileName);
    [id(9), helpstring("method CopyXML")] 
    HRESULT CopyXML(IUnknown * pTimeline, double dStart, double dEnd);
    [id(10), helpstring("method PasteXML")] 
    HRESULT PasteXML(IUnknown * pTimeline, double dStart);
    [id(11), helpstring("method Reset")] 
    HRESULT Reset( );
    [id(12), helpstring("method ReadXML")] 
    HRESULT ReadXML(IUnknown *pTimeline, IUnknown *pXML);
    [id(13), helpstring("method WriteXML")] 
    HRESULT WriteXML(IUnknown *pTimeline, BSTR *pbstrXML);
};

////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////
// USEFUL HELPER INTERFACES
////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////

//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// IAMErrorLog - an interface that receives error information from
// a timeline or a render engine.
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

[
    object,
    uuid(E43E73A2-0EFA-11d3-9601-00A0C9441E20),
    odl,
    helpstring("IAMErrorLog Interface"),
    pointer_default(unique)
]
interface IAMErrorLog : IUnknown
{
    [helpstring("method LogError")] HRESULT LogError(long Severity, BSTR pErrorString, long ErrorCode, long hresult, [in] VARIANT * pExtraInfo );
};

[
    object,
    uuid(963566DA-BE21-4eaf-88E9-35704F8F52A1),
    odl,
    helpstring("IAMSetErrorLog Interface"),
    pointer_default(unique)
]
interface IAMSetErrorLog : IUnknown
{
    [propget, helpstring("property ErrorLog")] HRESULT ErrorLog([out, retval] IAMErrorLog * *pVal);
    [propput, helpstring("property ErrorLog")] HRESULT ErrorLog([in] IAMErrorLog * newVal);
};

[
    object,
    uuid(0579154A-2B53-4994-B0D0-E773148EFF85),
    local,
    helpstring("ISampleGrabberCB Interface"),
    pointer_default(unique)
]
interface ISampleGrabberCB : IUnknown
{
    HRESULT SampleCB( double SampleTime, IMediaSample * pSample );
    HRESULT BufferCB( double SampleTime, BYTE * pBuffer, long BufferLen );
}

[
    object,
    uuid(6B652FFF-11FE-4fce-92AD-0266B5D7C78F),
    local,
    helpstring("ISampleGrabber Interface"),
    pointer_default(unique)
]
interface ISampleGrabber: IUnknown
{
    // set this to have the filter immediate stop after
    // garnishing a sample
    //
    HRESULT SetOneShot( BOOL OneShot );

    // set what media type we connect to. It can be partially
    // specified by setting only the major type, OR the major and
    // subtype, OR major, subtype, and the formattype.
    //
    HRESULT SetMediaType( const AM_MEDIA_TYPE * pType );

    // after something's connected to this filter, find out
    // what it is
    //
    HRESULT GetConnectedMediaType( AM_MEDIA_TYPE * pType );

    // call this to buffer incoming samples, so the next two methods will work
    // If this is not called, the next two methods will return
    // E_INVALIDARG
    //
    HRESULT SetBufferSamples( BOOL BufferThem );

    // pass in NULL for pBuffer to get out the buffer size you need to
    // allocate. This will NOT return a pointer to a compressed dib
    // any longer! It will return the IMediaSample's GetPointer buffer. 
    //
    HRESULT GetCurrentBuffer( [in,out] long * pBufferSize, [out] long * pBuffer );

    // return the currently buffered sample
    //
    HRESULT GetCurrentSample( [out,retval] IMediaSample ** ppSample );

    // if this callback is set, then it will be called for
    // every sample passing through the filter. Do not take a long time
    // in the callback for smooth playback (obviously!)
    //
    HRESULT SetCallback( ISampleGrabberCB * pCallback, long WhichMethodToCallback );
};

////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////
// THE LIBRARY ITSELF
////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////

[
    uuid(78530B68-61F9-11D2-8CAD-00A024580902),
    version(1.0),
    helpstring("Dexter 1.0 Type Library")
]
library DexterLib
{
    importlib("stdole2.tlb");

    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    // resize the input video to an output size, for uniformity within DES. 
    // DES will set the output media type and probably also put_Size. By setting
    // the output media type, DES is stating the resizer must produce only that
    // media type on the output pin, unless it is succeeded by a put_Size call.
    // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

    [
        object,
        uuid(4ada63a0-72d5-11d2-952a-0060081840bc),
        odl,
        helpstring("IResize Interface"),
        pointer_default(unique)
    ]
    interface IResize : IUnknown
    {
        HRESULT get_Size([out] int *piHeight, [out] int *piWidth, [out] long *pFlag);
        HRESULT get_InputSize([out] int *piHeight, [out] int *piWidth);
        HRESULT put_Size([in] int Height, [in] int Width, [in] long Flag);
        HRESULT get_MediaType([out] AM_MEDIA_TYPE *pmt);
        HRESULT put_MediaType([in] const AM_MEDIA_TYPE *pmt);
    };

    [
        uuid(78530B75-61F9-11D2-8CAD-00A024580902),
        helpstring("AMTimeline Class")
    ]
    coclass AMTimeline
    {
        [default] interface IAMTimeline;
        interface IPersistStream;
        interface IAMSetErrorLog;
    };

    [
        uuid(78530B78-61F9-11D2-8CAD-00A024580902),
        helpstring("IAMTimelineObj Class")
    ]
    coclass AMTimelineObj
    {
        [default] interface IAMTimelineObj;
    };

    [
        uuid(78530B7A-61F9-11D2-8CAD-00A024580902),
        helpstring("IAMTimelineSrc Class")
    ]
    coclass AMTimelineSrc
    {
        [default] interface IAMTimelineSrc;
        interface IAMTimelineObj;
        interface IAMTimelineEffectable;
        interface IAMTimelineSplittable;
    };

    [
        uuid(8F6C3C50-897B-11d2-8CFB-00A0C9441E20),
    ]
    coclass AMTimelineTrack
    {
        [default] interface IAMTimelineTrack;
        interface IAMTimelineObj;
        interface IAMTimelineEffectable;
        interface IAMTimelineTransable;
        interface IAMTimelineVirtualTrack;
        interface IAMTimelineSplittable;
    };

    [
        uuid(74D2EC80-6233-11d2-8CAD-00A024580902),
    ]
    coclass AMTimelineComp
    {
        [default] interface IAMTimelineComp;
        interface IAMTimelineObj;
        interface IAMTimelineEffectable;
        interface IAMTimelineTransable;
        interface IAMTimelineVirtualTrack;
    };

    [
        uuid(F6D371E1-B8A6-11d2-8023-00C0DF10D434),
    ]
    coclass AMTimelineGroup
    {
        [default] interface IAMTimelineGroup;
        interface IAMTimelineComp;
        interface IAMTimelineObj;
    };

    [
        uuid(74D2EC81-6233-11d2-8CAD-00A024580902),
    ]
    coclass AMTimelineTrans
    {
        [default] interface IAMTimelineTrans;
        interface IAMTimelineObj;
        interface IAMTimelineSplittable;
    };

    [
        uuid(74D2EC82-6233-11d2-8CAD-00A024580902),
    ]
        coclass AMTimelineEffect
    {
        [default] interface IAMTimelineEffect;
        interface IAMTimelineObj;
        interface IAMTimelineSplittable;
        interface IPropertyBag;
    };

    [
        uuid(64D8A8E0-80A2-11d2-8CF3-00A0C9441E20),
    ]
    coclass RenderEngine
    {
        [default] interface IRenderEngine;
        interface IRenderEngine2;
        interface IAMSetErrorLog;
    };

    [
        uuid(498B0949-BBE9-4072-98BE-6CCAEB79DC6F),
    ]
    coclass SmartRenderEngine
    {
        [default] interface IRenderEngine;
        interface ISmartRenderEngine;
        interface IAMSetErrorLog;
    };

    [
    uuid(036A9790-C153-11d2-9EF7-006008039E37),
    ]
        coclass AudMixer
    {
        [default] interface IBaseFilter;
    };

    [
        uuid(18C628EE-962A-11D2-8D08-00A0C9441E20),
        helpstring("Xml2Dex Class")
    ]
    coclass Xml2Dex
    {
        [default] interface IXml2Dex;
    };

    [
        uuid(CC1101F2-79DC-11D2-8CE6-00A0C9441E20),
        helpstring("MediaLocator Class")
    ]
    coclass MediaLocator
    {
        [default] interface IMediaLocator;
    };

    [
        uuid(ADF95821-DED7-11d2-ACBE-0080C75E246E),
        helpstring("Varying Property Holder")
    ]
    coclass PropertySetter
    {
        [default] interface IPropertySetter;
        interface IAMSetErrorLog;
    };

    [
        uuid(65BD0711-24D2-4ff7-9324-ED2E5D3ABAFA),
        helpstring("MediaDet Class")
    ]
    coclass MediaDet
    {
        [default] interface IMediaDet;
    };

    [
        uuid(C1F400A0-3F08-11d3-9F0B-006008039E37),
        helpstring("MsGrab Class")
    ]
    coclass SampleGrabber
    {
        [default] interface ISampleGrabber;
    };

    // useful for movie maker and other people
    [
        uuid(C1F400A4-3F08-11d3-9F0B-006008039E37),
        helpstring("NullRenderer Class")
    ]
    coclass NullRenderer
    {
        [default] interface IBaseFilter;
    };

    [
         uuid(BB44391D-6ABD-422f-9E2E-385C9DFF51FC),
         helpstring("DxtCompositor Class")
    ]
    coclass DxtCompositor
    {
         [default] interface IDxtCompositor;
    };

    [
         uuid(506D89AE-909A-44f7-9444-ABD575896E35),
         helpstring("DxtAlphaSetter Class")
    ]
    coclass DxtAlphaSetter
    {
         [default] interface IDxtAlphaSetter;
    };

    [
        uuid(DE75D012-7A65-11D2-8CEA-00A0C9441E20),
        helpstring("SMPTE wipe DXT")
    ]
    coclass DxtJpeg
    {
        [default] interface IDxtJpeg;
    };

    [
        uuid(0cfdd070-581a-11d2-9ee6-006008039e37),
    ]
    coclass ColorSource
    {
        [default] interface IBaseFilter;
    };

    [
        uuid(C5B19592-145E-11d3-9F04-006008039E37),
        helpstring("DxtKey Class")
    ]
    coclass DxtKey
    {
        [default] interface IDxtKey;
    };
};

// these are some error codes that we can/will return
enum
{
    E_NOTINTREE = 0x80040400,
    E_RENDER_ENGINE_IS_BROKEN = 0x80040401,
    E_MUST_INIT_RENDERER = 0x80040402,
    E_NOTDETERMINED = 0x80040403,
    E_NO_TIMELINE = 0x80040404,
    S_WARN_OUTPUTRESET = 40404
};

// These codes are given to the app in IAMErrorLog to help identify what went wrong

// Filename doesn't exist, or DShow doesn't recognize the filetype
// EXTRA - filename
cpp_quote("#define DEX_IDS_BAD_SOURCE_NAME    1400")

// Filename doesn't exist or contains unknown data
// EXTRA - filename (maybe no codec?)
cpp_quote("#define DEX_IDS_BAD_SOURCE_NAME2    1401")

// filename was required, but wasn't given
cpp_quote("#define DEX_IDS_MISSING_SOURCE_NAME    1402")

// cannot parse data provided by this source
// !!! what source?
cpp_quote("#define DEX_IDS_UNKNOWN_SOURCE    1403")

// unexpected error - some DShow component not installed correctly
cpp_quote("#define DEX_IDS_INSTALL_PROBLEM    1404")

// Source filter does not accept filenames
// !!! What source?
cpp_quote("#define DEX_IDS_NO_SOURCE_NAMES    1405")

// The group's mediatype is not supported
// EXTRA - gives you an integer group number
cpp_quote("#define DEX_IDS_BAD_MEDIATYPE    1406")

// Invalid stream number for a source
// EXTRA - gives the stream number !!! should identify which source!
cpp_quote("#define DEX_IDS_STREAM_NUMBER    1407")

// You ran out of memory
cpp_quote("#define DEX_IDS_OUTOFMEMORY        1408")

// One bitmap in a sequence was not the same type as the others
// EXTRA - gives the bitmap name
cpp_quote("#define DEX_IDS_DIBSEQ_NOTALLSAME    1409")

// Clip's mediatimes are invalid, or DibSeq too short, or a previous error caused this
// !!! Needs to give the clip name
cpp_quote("#define DEX_IDS_CLIPTOOSHORT        1410")

// Clsid of FX/Transition is not a DirectX Transform
// EXTRA - gives the CLSID
cpp_quote("#define DEX_IDS_INVALID_DXT        1411")

// Default FX/Transition Clsid is not a DirectX Transform"
// EXTRA - gives the CLSID
cpp_quote("#define DEX_IDS_INVALID_DEFAULT_DXT    1412")

// Your version of DX doesn't support 3D transforms"
// EXTRA - gives the CLSID of the 3D transform you tried to use
cpp_quote("#define DEX_IDS_NO_3D        1413")

// This DirectX Transform is not the right kind, or is broken
// EXTRA - gives the CLSID of the broken transform
cpp_quote("#define DEX_IDS_BROKEN_DXT        1414")

// No such property exists on an object
// EXTRA - gives the name of the property (if given as a string)
cpp_quote("#define DEX_IDS_NO_SUCH_PROPERTY    1415")

// Illegal value for a property
// EXTRA - gives the VARIANT value that was illegal
cpp_quote("#define DEX_IDS_ILLEGAL_PROPERTY_VAL    1416")

// Syntax error in XML file at line:
// EXTRA - gives I4 line number, if available
cpp_quote("#define DEX_IDS_INVALID_XML        1417")

// Can't find filter specified in XML by Category and Instance
// EXTRA - gives friendly name (instance)
cpp_quote("#define DEX_IDS_CANT_FIND_FILTER    1418")

// Disk error writing XML file
cpp_quote("#define DEX_IDS_DISK_WRITE_ERROR    1419")

// Clsid not a valid DShow audio effect filter
// EXTRA - gives the CLSID
cpp_quote("#define DEX_IDS_INVALID_AUDIO_FX    1420")

// Cannot find compressor for smart recompression type
cpp_quote("#define DEX_IDS_CANT_FIND_COMPRESSOR 1421")



// !!! Here go problems hooking up sources or finding codecs


// THE FOLLOWING SHOULD NEVER HAPPEN - please call me if they do

// Unexpected error in parsing the timeline
cpp_quote("#define DEX_IDS_TIMELINE_PARSE    1426")
// Unexpected error building the filtergraph
cpp_quote("#define DEX_IDS_GRAPH_ERROR        1427")
// Unexpected error with the internal grid
cpp_quote("#define DEX_IDS_GRID_ERROR        1428")
// Unexpected error getting an interface
cpp_quote("#define DEX_IDS_INTERFACE_ERROR    1429")

// these are the enumeration categories for effects
//
cpp_quote("EXTERN_GUID(CLSID_VideoEffects1Category, 0xcc7bfb42, 0xf175, 0x11d1, 0xa3, 0x92, 0x0, 0xe0, 0x29, 0x1f, 0x39, 0x59);")
cpp_quote("EXTERN_GUID(CLSID_VideoEffects2Category, 0xcc7bfb43, 0xf175, 0x11d1, 0xa3, 0x92, 0x0, 0xe0, 0x29, 0x1f, 0x39, 0x59);")
cpp_quote("EXTERN_GUID(CLSID_AudioEffects1Category, 0xcc7bfb44, 0xf175, 0x11d1, 0xa3, 0x92, 0x0, 0xe0, 0x29, 0x1f, 0x39, 0x59);")
cpp_quote("EXTERN_GUID(CLSID_AudioEffects2Category, 0xcc7bfb45, 0xf175, 0x11d1, 0xa3, 0x92, 0x0, 0xe0, 0x29, 0x1f, 0x39, 0x59);")