This file is indexed.

/usr/share/gtk-doc/html/gst-plugins-base-libs-0.10/gst-plugins-base-libs-gstringbuffer.html is in gstreamer0.10-plugins-base-doc 0.10.36-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

   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
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>gstringbuffer</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
<link rel="home" href="index.html" title="GStreamer Base Plugins 0.10 Library Reference Manual">
<link rel="up" href="gstreamer-audio.html" title="Audio Library">
<link rel="prev" href="gst-plugins-base-libs-gstmultichannel.html" title="gstmultichannel">
<link rel="next" href="gst-plugins-base-libs-gstaudioiec61937.html" title="gstaudioiec61937">
<meta name="generator" content="GTK-Doc V1.18 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="gst-plugins-base-libs-gstmultichannel.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="gstreamer-audio.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">GStreamer Base Plugins 0.10 Library Reference Manual</th>
<td><a accesskey="n" href="gst-plugins-base-libs-gstaudioiec61937.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#gst-plugins-base-libs-gstringbuffer.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#gst-plugins-base-libs-gstringbuffer.description" class="shortcut">Description</a>
                   | 
                  <a href="#gst-plugins-base-libs-gstringbuffer.object-hierarchy" class="shortcut">Object Hierarchy</a>
</td></tr>
</table>
<div class="refentry">
<a name="gst-plugins-base-libs-gstringbuffer"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="gst-plugins-base-libs-gstringbuffer.top_of_page"></a>gstringbuffer</span></h2>
<p>gstringbuffer — Base class for audio ringbuffer implementations</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv">
<a name="gst-plugins-base-libs-gstringbuffer.synopsis"></a><h2>Synopsis</h2>
<a name="GstRingBuffer"></a><pre class="synopsis">
#include &lt;gst/audio/gstringbuffer.h&gt;

struct              <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer-struct" title="struct GstRingBuffer">GstRingBuffer</a>;
struct              <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferClass" title="struct GstRingBufferClass">GstRingBufferClass</a>;
struct              <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferSpec" title="struct GstRingBufferSpec">GstRingBufferSpec</a>;
<span class="returnvalue">void</span>                (<a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferCallback" title="GstRingBufferCallback ()">*GstRingBufferCallback</a>)            (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *rbuf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint8</span> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> len</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);
enum                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferSegState" title="enum GstRingBufferSegState">GstRingBufferSegState</a>;
enum                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferState" title="enum GstRingBufferState">GstRingBufferState</a>;
enum                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstBufferFormat" title="enum GstBufferFormat">GstBufferFormat</a>;
enum                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstBufferFormatType" title="enum GstBufferFormatType">GstBufferFormatType</a>;
#define             <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GST-RING-BUFFER-BROADCAST:CAPS" title="GST_RING_BUFFER_BROADCAST()">GST_RING_BUFFER_BROADCAST</a>           (buf)
#define             <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GST-RING-BUFFER-GET-COND:CAPS" title="GST_RING_BUFFER_GET_COND()">GST_RING_BUFFER_GET_COND</a>            (buf)
#define             <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GST-RING-BUFFER-SIGNAL:CAPS" title="GST_RING_BUFFER_SIGNAL()">GST_RING_BUFFER_SIGNAL</a>              (buf)
#define             <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GST-RING-BUFFER-WAIT:CAPS" title="GST_RING_BUFFER_WAIT()">GST_RING_BUFFER_WAIT</a>                (buf)
<span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-set-callback" title="gst_ring_buffer_set_callback ()">gst_ring_buffer_set_callback</a>        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferCallback" title="GstRingBufferCallback ()"><span class="type">GstRingBufferCallback</span></a> cb</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-acquire" title="gst_ring_buffer_acquire ()">gst_ring_buffer_acquire</a>             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferSpec" title="struct GstRingBufferSpec"><span class="type">GstRingBufferSpec</span></a> *spec</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-release" title="gst_ring_buffer_release ()">gst_ring_buffer_release</a>             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-is-acquired" title="gst_ring_buffer_is_acquired ()">gst_ring_buffer_is_acquired</a>         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-activate" title="gst_ring_buffer_activate ()">gst_ring_buffer_activate</a>            (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> active</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-is-active" title="gst_ring_buffer_is_active ()">gst_ring_buffer_is_active</a>           (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-start" title="gst_ring_buffer_start ()">gst_ring_buffer_start</a>               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-pause" title="gst_ring_buffer_pause ()">gst_ring_buffer_pause</a>               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-stop" title="gst_ring_buffer_stop ()">gst_ring_buffer_stop</a>                (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>               <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-delay" title="gst_ring_buffer_delay ()">gst_ring_buffer_delay</a>               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<span class="returnvalue">guint64</span>             <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-samples-done" title="gst_ring_buffer_samples_done ()">gst_ring_buffer_samples_done</a>        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-set-sample" title="gst_ring_buffer_set_sample ()">gst_ring_buffer_set_sample</a>          (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint64</span> sample</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>               <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-commit" title="gst_ring_buffer_commit ()">gst_ring_buffer_commit</a>              (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint64</span> sample</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> len</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>               <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-commit-full" title="gst_ring_buffer_commit_full ()">gst_ring_buffer_commit_full</a>         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint64</span> *sample</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> in_samples</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> out_samples</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *accum</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-convert" title="gst_ring_buffer_convert ()">gst_ring_buffer_convert</a>             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstFormat.html#GstFormat"><span class="type">GstFormat</span></a> src_fmt</code></em>,
                                                         <em class="parameter"><code><span class="type">gint64</span> src_val</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstFormat.html#GstFormat"><span class="type">GstFormat</span></a> dest_fmt</code></em>,
                                                         <em class="parameter"><code><span class="type">gint64</span> *dest_val</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-prepare-read" title="gst_ring_buffer_prepare_read ()">gst_ring_buffer_prepare_read</a>        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *segment</code></em>,
                                                         <em class="parameter"><code><span class="type">guint8</span> **readptr</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *len</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>               <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-read" title="gst_ring_buffer_read ()">gst_ring_buffer_read</a>                (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint64</span> sample</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> len</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-clear" title="gst_ring_buffer_clear ()">gst_ring_buffer_clear</a>               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> segment</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-clear-all" title="gst_ring_buffer_clear_all ()">gst_ring_buffer_clear_all</a>           (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-advance" title="gst_ring_buffer_advance ()">gst_ring_buffer_advance</a>             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> advance</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-close-device" title="gst_ring_buffer_close_device ()">gst_ring_buffer_close_device</a>        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-open-device" title="gst_ring_buffer_open_device ()">gst_ring_buffer_open_device</a>         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-device-is-open" title="gst_ring_buffer_device_is_open ()">gst_ring_buffer_device_is_open</a>      (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-may-start" title="gst_ring_buffer_may_start ()">gst_ring_buffer_may_start</a>           (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> allowed</code></em>);
<a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-parse-caps" title="gst_ring_buffer_parse_caps ()">gst_ring_buffer_parse_caps</a>          (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferSpec" title="struct GstRingBufferSpec"><span class="type">GstRingBufferSpec</span></a> *spec</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a> *caps</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-set-flushing" title="gst_ring_buffer_set_flushing ()">gst_ring_buffer_set_flushing</a>        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> flushing</code></em>);
</pre>
</div>
<div class="refsect1">
<a name="gst-plugins-base-libs-gstringbuffer.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="synopsis">
  <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>
   +----<a href="/usr/share/gtk-doc/html/gstreamer-0.10/GstObject.html">GstObject</a>
         +----GstRingBuffer
</pre>
</div>
<div class="refsect1">
<a name="gst-plugins-base-libs-gstringbuffer.description"></a><h2>Description</h2>
<p>
</p>
<div class="refsect2">
<a name="idp12967152"></a><p>
This object is the base class for audio ringbuffers used by the base
audio source and sink classes.
</p>
<p>
The ringbuffer abstracts a circular buffer of data. One reader and
one writer can operate on the data from different threads in a lockfree
manner. The base class is sufficiently flexible to be used as an
abstraction for DMA based ringbuffers as well as a pure software
implementations.
</p>
</div>
<p>
</p>
<p>
Last reviewed on 2006-02-02 (0.10.4)
</p>
</div>
<div class="refsect1">
<a name="gst-plugins-base-libs-gstringbuffer.details"></a><h2>Details</h2>
<div class="refsect2">
<a name="GstRingBuffer-struct"></a><h3>struct GstRingBuffer</h3>
<pre class="programlisting">struct GstRingBuffer {
  GCond                 *cond;
  gboolean               open;
  gboolean               acquired;
  GstBuffer             *data;
  GstRingBufferSpec      spec;
  GstRingBufferSegState *segstate;
  gint                   samples_per_seg;
  guint8                *empty_seg;

  gint                   state;
  gint                   segdone;
  gint                   segbase;
  gint                   waiting;
};
</pre>
<p>
The ringbuffer base class structure.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Threads.html#GCond"><span class="type">GCond</span></a> *<em class="structfield"><code><a name="GstRingBuffer-struct.cond"></a>cond</code></em>;</span></p></td>
<td>used to signal start/stop/pause/resume actions</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> <em class="structfield"><code><a name="GstRingBuffer-struct.open"></a>open</code></em>;</span></p></td>
<td>boolean indicating that the ringbuffer is open</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> <em class="structfield"><code><a name="GstRingBuffer-struct.acquired"></a>acquired</code></em>;</span></p></td>
<td>boolean indicating that the ringbuffer is acquired</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstBuffer.html#GstBuffer"><span class="type">GstBuffer</span></a> *<em class="structfield"><code><a name="GstRingBuffer-struct.data"></a>data</code></em>;</span></p></td>
<td>data in the ringbuffer</td>
</tr>
<tr>
<td><p><span class="term"><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferSpec" title="struct GstRingBufferSpec"><span class="type">GstRingBufferSpec</span></a> <em class="structfield"><code><a name="GstRingBuffer-struct.spec"></a>spec</code></em>;</span></p></td>
<td>format and layout of the ringbuffer data</td>
</tr>
<tr>
<td><p><span class="term"><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferSegState" title="enum GstRingBufferSegState"><span class="type">GstRingBufferSegState</span></a> *<em class="structfield"><code><a name="GstRingBuffer-struct.segstate"></a>segstate</code></em>;</span></p></td>
<td>status of each segment in the ringbuffer (unused)</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBuffer-struct.samples-per-seg"></a>samples_per_seg</code></em>;</span></p></td>
<td>number of samples in one segment</td>
</tr>
<tr>
<td><p><span class="term"><span class="type">guint8</span> *<em class="structfield"><code><a name="GstRingBuffer-struct.empty-seg"></a>empty_seg</code></em>;</span></p></td>
<td>pointer to memory holding one segment of silence samples</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBuffer-struct.state"></a>state</code></em>;</span></p></td>
<td>state of the buffer</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBuffer-struct.segdone"></a>segdone</code></em>;</span></p></td>
<td>readpointer in the ringbuffer</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBuffer-struct.segbase"></a>segbase</code></em>;</span></p></td>
<td>segment corresponding to segment 0 (unused)</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBuffer-struct.waiting"></a>waiting</code></em>;</span></p></td>
<td>is a reader or writer waiting for a free segment</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="GstRingBufferClass"></a><h3>struct GstRingBufferClass</h3>
<pre class="programlisting">struct GstRingBufferClass {
  GstObjectClass parent_class;

  gboolean     (*open_device)  (GstRingBuffer *buf);
  gboolean     (*acquire)      (GstRingBuffer *buf, GstRingBufferSpec *spec);
  gboolean     (*release)      (GstRingBuffer *buf);
  gboolean     (*close_device) (GstRingBuffer *buf);

  gboolean     (*start)        (GstRingBuffer *buf);
  gboolean     (*pause)        (GstRingBuffer *buf);
  gboolean     (*resume)       (GstRingBuffer *buf);
  gboolean     (*stop)         (GstRingBuffer *buf);

  guint        (*delay)        (GstRingBuffer *buf);

  /* ABI added */
  gboolean     (*activate)     (GstRingBuffer *buf, gboolean active);

  guint        (*commit)       (GstRingBuffer * buf, guint64 *sample,
                                guchar * data, gint in_samples,
                                gint out_samples, gint * accum);

  void         (*clear_all)    (GstRingBuffer * buf);
};
</pre>
<p>
The vmethods that subclasses can override to implement the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/gstreamer-0.10/GstObject.html#GstObjectClass"><span class="type">GstObjectClass</span></a> <em class="structfield"><code><a name="GstRingBufferClass.parent-class"></a>parent_class</code></em>;</span></p></td>
<td>parent class</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.open-device"></a>open_device</code></em> ()</span></p></td>
<td>open the device, don't set any params or allocate anything</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.acquire"></a>acquire</code></em> ()</span></p></td>
<td>allocate the resources for the ringbuffer using the given spec</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.release"></a>release</code></em> ()</span></p></td>
<td>free resources of the ringbuffer</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.close-device"></a>close_device</code></em> ()</span></p></td>
<td>close the device</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.start"></a>start</code></em> ()</span></p></td>
<td>start processing of samples</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.pause"></a>pause</code></em> ()</span></p></td>
<td>pause processing of samples</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.resume"></a>resume</code></em> ()</span></p></td>
<td>resume processing of samples after pause</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.stop"></a>stop</code></em> ()</span></p></td>
<td>stop processing of samples</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.delay"></a>delay</code></em> ()</span></p></td>
<td>get number of samples queued in device</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.activate"></a>activate</code></em> ()</span></p></td>
<td>activate the thread that starts pulling and monitoring the
consumed segments in the device. Since 0.10.22</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.commit"></a>commit</code></em> ()</span></p></td>
<td>write samples into the ringbuffer</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GstRingBufferClass.clear-all"></a>clear_all</code></em> ()</span></p></td>
<td>clear the entire ringbuffer Since 0.10.24</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="GstRingBufferSpec"></a><h3>struct GstRingBufferSpec</h3>
<pre class="programlisting">struct GstRingBufferSpec {
  /* in */
  GstCaps  *caps;               /* the caps of the buffer */

  /* in/out */
  GstBufferFormatType   type;
  GstBufferFormat format;
  gboolean  sign;
  gboolean  bigend;
  gint      width;
  gint      depth;
  gint      rate;
  gint      channels;

  guint64  latency_time;        /* the required/actual latency time, this is the
				 * actual the size of one segment and the
				 * minimum possible latency we can achieve. */
  guint64  buffer_time;         /* the required/actual time of the buffer, this is
				 * the total size of the buffer and maximum
				 * latency we can compensate for. */
  gint     segsize;             /* size of one buffer segment in bytes, this value
				 * should be chosen to match latency_time as
				 * well as possible. */
  gint     segtotal;            /* total number of segments, this value is the
				 * number of segments of @segsize and should be
				 * chosen so that it matches buffer_time as
				 * close as possible. */
  /* out */
  gint     bytes_per_sample;    /* number of bytes of one sample */
  guint8   silence_sample[32];  /* bytes representing silence */

  /* ABI added 0.10.20 */
  gint     seglatency;          /* number of segments queued in the lower
				 * level device, defaults to segtotal. */
};
</pre>
<p>
The structure containing the format specification of the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a> *<em class="structfield"><code><a name="GstRingBufferSpec.caps"></a>caps</code></em>;</span></p></td>
<td>The caps that generated the Spec.</td>
</tr>
<tr>
<td><p><span class="term"><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstBufferFormatType" title="enum GstBufferFormatType"><span class="type">GstBufferFormatType</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.type"></a>type</code></em>;</span></p></td>
<td>the sample type</td>
</tr>
<tr>
<td><p><span class="term"><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstBufferFormat" title="enum GstBufferFormat"><span class="type">GstBufferFormat</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.format"></a>format</code></em>;</span></p></td>
<td>the sample format</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.sign"></a>sign</code></em>;</span></p></td>
<td>the sample sign</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.bigend"></a>bigend</code></em>;</span></p></td>
<td>the endianness of the samples</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.width"></a>width</code></em>;</span></p></td>
<td>the width of the samples</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.depth"></a>depth</code></em>;</span></p></td>
<td>th depth of the samples</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.rate"></a>rate</code></em>;</span></p></td>
<td>the samplerate</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.channels"></a>channels</code></em>;</span></p></td>
<td>the number of channels</td>
</tr>
<tr>
<td><p><span class="term"><span class="type">guint64</span> <em class="structfield"><code><a name="GstRingBufferSpec.latency-time"></a>latency_time</code></em>;</span></p></td>
<td>the latency in microseconds</td>
</tr>
<tr>
<td><p><span class="term"><span class="type">guint64</span> <em class="structfield"><code><a name="GstRingBufferSpec.buffer-time"></a>buffer_time</code></em>;</span></p></td>
<td>the total buffer size in microseconds</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.segsize"></a>segsize</code></em>;</span></p></td>
<td>the size of one segment in bytes</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.segtotal"></a>segtotal</code></em>;</span></p></td>
<td>the total number of segments</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.bytes-per-sample"></a>bytes_per_sample</code></em>;</span></p></td>
<td>number of bytes in one sample</td>
</tr>
<tr>
<td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="GstRingBufferSpec.silence-sample"></a>silence_sample</code></em>[32];</span></p></td>
<td>bytes representing one sample of silence</td>
</tr>
<tr>
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstRingBufferSpec.seglatency"></a>seglatency</code></em>;</span></p></td>
<td>number of segments queued in the lower level device,
defaults to segtotal</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="GstRingBufferCallback"></a><h3>GstRingBufferCallback ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                (*GstRingBufferCallback)            (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *rbuf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint8</span> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> len</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);</pre>
<p>
This function is set with <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-set-callback" title="gst_ring_buffer_set_callback ()"><code class="function">gst_ring_buffer_set_callback()</code></a> and is
called to fill the memory at <em class="parameter"><code>data</code></em> with <em class="parameter"><code>len</code></em> bytes of samples.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>rbuf</code></em> :</span></p></td>
<td>a <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>data</code></em> :</span></p></td>
<td>target to fill</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>len</code></em> :</span></p></td>
<td>amount to fill</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
<td>user data</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="GstRingBufferSegState"></a><h3>enum GstRingBufferSegState</h3>
<pre class="programlisting">typedef enum {
  GST_SEGSTATE_INVALID,
  GST_SEGSTATE_EMPTY,
  GST_SEGSTATE_FILLED,
  GST_SEGSTATE_PARTIAL
} GstRingBufferSegState;
</pre>
<p>
The state of a segment in the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><a name="GST-SEGSTATE-INVALID:CAPS"></a><span class="term"><code class="literal">GST_SEGSTATE_INVALID</code></span></p></td>
<td>The content of the segment is invalid
</td>
</tr>
<tr>
<td><p><a name="GST-SEGSTATE-EMPTY:CAPS"></a><span class="term"><code class="literal">GST_SEGSTATE_EMPTY</code></span></p></td>
<td>The segment is empty
</td>
</tr>
<tr>
<td><p><a name="GST-SEGSTATE-FILLED:CAPS"></a><span class="term"><code class="literal">GST_SEGSTATE_FILLED</code></span></p></td>
<td>The segment contains valid data
</td>
</tr>
<tr>
<td><p><a name="GST-SEGSTATE-PARTIAL:CAPS"></a><span class="term"><code class="literal">GST_SEGSTATE_PARTIAL</code></span></p></td>
<td>The segment partially contains valid data
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="GstRingBufferState"></a><h3>enum GstRingBufferState</h3>
<pre class="programlisting">typedef enum {
  GST_RING_BUFFER_STATE_STOPPED,
  GST_RING_BUFFER_STATE_PAUSED,
  GST_RING_BUFFER_STATE_STARTED
} GstRingBufferState;
</pre>
<p>
The state of the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><a name="GST-RING-BUFFER-STATE-STOPPED:CAPS"></a><span class="term"><code class="literal">GST_RING_BUFFER_STATE_STOPPED</code></span></p></td>
<td>The ringbuffer is stopped
</td>
</tr>
<tr>
<td><p><a name="GST-RING-BUFFER-STATE-PAUSED:CAPS"></a><span class="term"><code class="literal">GST_RING_BUFFER_STATE_PAUSED</code></span></p></td>
<td>The ringbuffer is paused
</td>
</tr>
<tr>
<td><p><a name="GST-RING-BUFFER-STATE-STARTED:CAPS"></a><span class="term"><code class="literal">GST_RING_BUFFER_STATE_STARTED</code></span></p></td>
<td>The ringbuffer is started
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="GstBufferFormat"></a><h3>enum GstBufferFormat</h3>
<pre class="programlisting">typedef enum {
  GST_UNKNOWN,

  GST_S8,
  GST_U8,

  GST_S16_LE,
  GST_S16_BE,
  GST_U16_LE,
  GST_U16_BE,

  GST_S24_LE,
  GST_S24_BE,
  GST_U24_LE,
  GST_U24_BE,

  GST_S32_LE,
  GST_S32_BE,
  GST_U32_LE,
  GST_U32_BE,

  GST_S24_3LE,
  GST_S24_3BE,
  GST_U24_3LE,
  GST_U24_3BE,
  GST_S20_3LE,
  GST_S20_3BE,
  GST_U20_3LE,
  GST_U20_3BE,
  GST_S18_3LE,
  GST_S18_3BE,
  GST_U18_3LE,
  GST_U18_3BE,

  GST_FLOAT32_LE,
  GST_FLOAT32_BE,

  GST_FLOAT64_LE,
  GST_FLOAT64_BE,

  GST_MU_LAW,
  GST_A_LAW,
  GST_IMA_ADPCM,
  GST_MPEG,
  GST_GSM,
  GST_IEC958,
  GST_AC3,
  GST_EAC3,
  GST_DTS,
  GST_MPEG2_AAC,
  GST_MPEG4_AAC,
} GstBufferFormat;
</pre>
<p>
The detailed format of the samples in the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><a name="GST-UNKNOWN:CAPS"></a><span class="term"><code class="literal">GST_UNKNOWN</code></span></p></td>
<td>unspecified
</td>
</tr>
<tr>
<td><p><a name="GST-S8:CAPS"></a><span class="term"><code class="literal">GST_S8</code></span></p></td>
<td>integer signed 8 bit
</td>
</tr>
<tr>
<td><p><a name="GST-U8:CAPS"></a><span class="term"><code class="literal">GST_U8</code></span></p></td>
<td>integer unsigned 8 bit
</td>
</tr>
<tr>
<td><p><a name="GST-S16-LE:CAPS"></a><span class="term"><code class="literal">GST_S16_LE</code></span></p></td>
<td>integer signed 16 bit little endian
</td>
</tr>
<tr>
<td><p><a name="GST-S16-BE:CAPS"></a><span class="term"><code class="literal">GST_S16_BE</code></span></p></td>
<td>integer signed 16 bit big endian
</td>
</tr>
<tr>
<td><p><a name="GST-U16-LE:CAPS"></a><span class="term"><code class="literal">GST_U16_LE</code></span></p></td>
<td>integer unsigned 16 bit little endian
</td>
</tr>
<tr>
<td><p><a name="GST-U16-BE:CAPS"></a><span class="term"><code class="literal">GST_U16_BE</code></span></p></td>
<td>integer unsigned 16 bit big endian
</td>
</tr>
<tr>
<td><p><a name="GST-S24-LE:CAPS"></a><span class="term"><code class="literal">GST_S24_LE</code></span></p></td>
<td>integer signed 24 bit little endian
</td>
</tr>
<tr>
<td><p><a name="GST-S24-BE:CAPS"></a><span class="term"><code class="literal">GST_S24_BE</code></span></p></td>
<td>integer signed 24 bit big endian
</td>
</tr>
<tr>
<td><p><a name="GST-U24-LE:CAPS"></a><span class="term"><code class="literal">GST_U24_LE</code></span></p></td>
<td>integer unsigned 24 bit little endian
</td>
</tr>
<tr>
<td><p><a name="GST-U24-BE:CAPS"></a><span class="term"><code class="literal">GST_U24_BE</code></span></p></td>
<td>integer unsigned 24 bit big endian
</td>
</tr>
<tr>
<td><p><a name="GST-S32-LE:CAPS"></a><span class="term"><code class="literal">GST_S32_LE</code></span></p></td>
<td>integer signed 32 bit little endian
</td>
</tr>
<tr>
<td><p><a name="GST-S32-BE:CAPS"></a><span class="term"><code class="literal">GST_S32_BE</code></span></p></td>
<td>integer signed 32 bit big endian
</td>
</tr>
<tr>
<td><p><a name="GST-U32-LE:CAPS"></a><span class="term"><code class="literal">GST_U32_LE</code></span></p></td>
<td>integer unsigned 32 bit little endian
</td>
</tr>
<tr>
<td><p><a name="GST-U32-BE:CAPS"></a><span class="term"><code class="literal">GST_U32_BE</code></span></p></td>
<td>integer unsigned 32 bit big endian
</td>
</tr>
<tr>
<td><p><a name="GST-S24-3LE:CAPS"></a><span class="term"><code class="literal">GST_S24_3LE</code></span></p></td>
<td>integer signed 24 bit little endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-S24-3BE:CAPS"></a><span class="term"><code class="literal">GST_S24_3BE</code></span></p></td>
<td>integer signed 24 bit big endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-U24-3LE:CAPS"></a><span class="term"><code class="literal">GST_U24_3LE</code></span></p></td>
<td>integer unsigned 24 bit little endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-U24-3BE:CAPS"></a><span class="term"><code class="literal">GST_U24_3BE</code></span></p></td>
<td>integer unsigned 24 bit big endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-S20-3LE:CAPS"></a><span class="term"><code class="literal">GST_S20_3LE</code></span></p></td>
<td>integer signed 20 bit little endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-S20-3BE:CAPS"></a><span class="term"><code class="literal">GST_S20_3BE</code></span></p></td>
<td>integer signed 20 bit big endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-U20-3LE:CAPS"></a><span class="term"><code class="literal">GST_U20_3LE</code></span></p></td>
<td>integer unsigned 20 bit little endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-U20-3BE:CAPS"></a><span class="term"><code class="literal">GST_U20_3BE</code></span></p></td>
<td>integer unsigned 20 bit big endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-S18-3LE:CAPS"></a><span class="term"><code class="literal">GST_S18_3LE</code></span></p></td>
<td>integer signed 18 bit little endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-S18-3BE:CAPS"></a><span class="term"><code class="literal">GST_S18_3BE</code></span></p></td>
<td>integer signed 18 bit big endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-U18-3LE:CAPS"></a><span class="term"><code class="literal">GST_U18_3LE</code></span></p></td>
<td>integer unsigned 18 bit little endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-U18-3BE:CAPS"></a><span class="term"><code class="literal">GST_U18_3BE</code></span></p></td>
<td>integer unsigned 18 bit big endian packed in 3 bytes
</td>
</tr>
<tr>
<td><p><a name="GST-FLOAT32-LE:CAPS"></a><span class="term"><code class="literal">GST_FLOAT32_LE</code></span></p></td>
<td>floating 32 bit little endian
</td>
</tr>
<tr>
<td><p><a name="GST-FLOAT32-BE:CAPS"></a><span class="term"><code class="literal">GST_FLOAT32_BE</code></span></p></td>
<td>floating 32 bit big endian
</td>
</tr>
<tr>
<td><p><a name="GST-FLOAT64-LE:CAPS"></a><span class="term"><code class="literal">GST_FLOAT64_LE</code></span></p></td>
<td>floating 64 bit little endian
</td>
</tr>
<tr>
<td><p><a name="GST-FLOAT64-BE:CAPS"></a><span class="term"><code class="literal">GST_FLOAT64_BE</code></span></p></td>
<td>floating 64 bit big endian
</td>
</tr>
<tr>
<td><p><a name="GST-MU-LAW:CAPS"></a><span class="term"><code class="literal">GST_MU_LAW</code></span></p></td>
<td>mu-law
</td>
</tr>
<tr>
<td><p><a name="GST-A-LAW:CAPS"></a><span class="term"><code class="literal">GST_A_LAW</code></span></p></td>
<td>a-law
</td>
</tr>
<tr>
<td><p><a name="GST-IMA-ADPCM:CAPS"></a><span class="term"><code class="literal">GST_IMA_ADPCM</code></span></p></td>
<td>ima adpcm
</td>
</tr>
<tr>
<td><p><a name="GST-MPEG:CAPS"></a><span class="term"><code class="literal">GST_MPEG</code></span></p></td>
<td>mpeg audio (but not aac)
</td>
</tr>
<tr>
<td><p><a name="GST-GSM:CAPS"></a><span class="term"><code class="literal">GST_GSM</code></span></p></td>
<td>gsm
</td>
</tr>
<tr>
<td><p><a name="GST-IEC958:CAPS"></a><span class="term"><code class="literal">GST_IEC958</code></span></p></td>
<td>IEC958 frames
</td>
</tr>
<tr>
<td><p><a name="GST-AC3:CAPS"></a><span class="term"><code class="literal">GST_AC3</code></span></p></td>
<td>ac3
</td>
</tr>
<tr>
<td><p><a name="GST-EAC3:CAPS"></a><span class="term"><code class="literal">GST_EAC3</code></span></p></td>
<td>eac3
</td>
</tr>
<tr>
<td><p><a name="GST-DTS:CAPS"></a><span class="term"><code class="literal">GST_DTS</code></span></p></td>
<td>dts
</td>
</tr>
<tr>
<td><p><a name="GST-MPEG2-AAC:CAPS"></a><span class="term"><code class="literal">GST_MPEG2_AAC</code></span></p></td>
<td>mpeg-2 aac
</td>
</tr>
<tr>
<td><p><a name="GST-MPEG4-AAC:CAPS"></a><span class="term"><code class="literal">GST_MPEG4_AAC</code></span></p></td>
<td>mpeg-4 aac
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="GstBufferFormatType"></a><h3>enum GstBufferFormatType</h3>
<pre class="programlisting">typedef enum {
  GST_BUFTYPE_LINEAR,
  GST_BUFTYPE_FLOAT,
  GST_BUFTYPE_MU_LAW,
  GST_BUFTYPE_A_LAW,
  GST_BUFTYPE_IMA_ADPCM,
  GST_BUFTYPE_MPEG,
  GST_BUFTYPE_GSM,
  GST_BUFTYPE_IEC958,
  GST_BUFTYPE_AC3,
  GST_BUFTYPE_EAC3,
  GST_BUFTYPE_DTS,
  GST_BUFTYPE_MPEG2_AAC,
  GST_BUFTYPE_MPEG4_AAC,
} GstBufferFormatType;
</pre>
<p>
The format of the samples in the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><a name="GST-BUFTYPE-LINEAR:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_LINEAR</code></span></p></td>
<td>samples in linear PCM
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-FLOAT:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_FLOAT</code></span></p></td>
<td>samples in float
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-MU-LAW:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_MU_LAW</code></span></p></td>
<td>samples in mulaw
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-A-LAW:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_A_LAW</code></span></p></td>
<td>samples in alaw
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-IMA-ADPCM:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_IMA_ADPCM</code></span></p></td>
<td>samples in ima adpcm
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-MPEG:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_MPEG</code></span></p></td>
<td>samples in mpeg audio (but not AAC) format
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-GSM:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_GSM</code></span></p></td>
<td>samples in gsm format
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-IEC958:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_IEC958</code></span></p></td>
<td>samples in IEC958 frames (e.g. AC3)
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-AC3:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_AC3</code></span></p></td>
<td>samples in AC3 format
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-EAC3:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_EAC3</code></span></p></td>
<td>samples in EAC3 format
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-DTS:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_DTS</code></span></p></td>
<td>samples in DTS format
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-MPEG2-AAC:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_MPEG2_AAC</code></span></p></td>
<td>samples in MPEG-2 AAC format
</td>
</tr>
<tr>
<td><p><a name="GST-BUFTYPE-MPEG4-AAC:CAPS"></a><span class="term"><code class="literal">GST_BUFTYPE_MPEG4_AAC</code></span></p></td>
<td>samples in MPEG-4 AAC format
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="GST-RING-BUFFER-BROADCAST:CAPS"></a><h3>GST_RING_BUFFER_BROADCAST()</h3>
<pre class="programlisting">#define GST_RING_BUFFER_BROADCAST(buf)(g_cond_broadcast (GST_RING_BUFFER_GET_COND (buf)))
</pre>
</div>
<hr>
<div class="refsect2">
<a name="GST-RING-BUFFER-GET-COND:CAPS"></a><h3>GST_RING_BUFFER_GET_COND()</h3>
<pre class="programlisting">#define GST_RING_BUFFER_GET_COND(buf) (((GstRingBuffer *)buf)-&gt;cond)
</pre>
</div>
<hr>
<div class="refsect2">
<a name="GST-RING-BUFFER-SIGNAL:CAPS"></a><h3>GST_RING_BUFFER_SIGNAL()</h3>
<pre class="programlisting">#define GST_RING_BUFFER_SIGNAL(buf)   (g_cond_signal (GST_RING_BUFFER_GET_COND (buf)))
</pre>
</div>
<hr>
<div class="refsect2">
<a name="GST-RING-BUFFER-WAIT:CAPS"></a><h3>GST_RING_BUFFER_WAIT()</h3>
<pre class="programlisting">#define GST_RING_BUFFER_WAIT(buf)     (g_cond_wait (GST_RING_BUFFER_GET_COND (buf), GST_OBJECT_GET_LOCK (buf)))
</pre>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-set-callback"></a><h3>gst_ring_buffer_set_callback ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gst_ring_buffer_set_callback        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferCallback" title="GstRingBufferCallback ()"><span class="type">GstRingBufferCallback</span></a> cb</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);</pre>
<p>
Sets the given callback function on the buffer. This function
will be called every time a segment has been written to a device.
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to set the callback on</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>cb</code></em> :</span></p></td>
<td>the callback to set</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
<td>user data passed to the callback</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-acquire"></a><h3>gst_ring_buffer_acquire ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_acquire             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferSpec" title="struct GstRingBufferSpec"><span class="type">GstRingBufferSpec</span></a> *spec</code></em>);</pre>
<p>
Allocate the resources for the ringbuffer. This function fills
in the data pointer of the ring buffer with a valid <a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstBuffer.html#GstBuffer"><span class="type">GstBuffer</span></a>
to which samples can be written.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to acquire</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>spec</code></em> :</span></p></td>
<td>the specs of the buffer</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device could be acquired, FALSE on error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-release"></a><h3>gst_ring_buffer_release ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_release             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Free the resources of the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to release</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device could be released, FALSE on error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-is-acquired"></a><h3>gst_ring_buffer_is_acquired ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_is_acquired         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Check if the ringbuffer is acquired and ready to use.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to check</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the ringbuffer is acquired, FALSE on error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-activate"></a><h3>gst_ring_buffer_activate ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_activate            (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> active</code></em>);</pre>
<p>
Activate <em class="parameter"><code>buf</code></em> to start or stop pulling data.
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to activate</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>active</code></em> :</span></p></td>
<td>the new mode</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device could be activated in the requested mode,
FALSE on error.</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 0.10.22.</p>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-is-active"></a><h3>gst_ring_buffer_is_active ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_is_active           (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Check if <em class="parameter"><code>buf</code></em> is activated.
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device is active.</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 0.10.22.</p>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-start"></a><h3>gst_ring_buffer_start ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_start               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Start processing samples from the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to start</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device could be started, FALSE on error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-pause"></a><h3>gst_ring_buffer_pause ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_pause               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Pause processing samples from the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to pause</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device could be paused, FALSE on error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-stop"></a><h3>gst_ring_buffer_stop ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_stop                (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Stop processing samples from the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to stop</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device could be stopped, FALSE on error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-delay"></a><h3>gst_ring_buffer_delay ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>               gst_ring_buffer_delay               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Get the number of samples queued in the audio device. This is
usually less than the segment size but can be bigger when the
implementation uses another internal buffer between the audio
device.
</p>
<p>
For playback ringbuffers this is the amount of samples transfered from the
ringbuffer to the device but still not played.
</p>
<p>
For capture ringbuffers this is the amount of samples in the device that are
not yet transfered to the ringbuffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to query</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>The number of samples queued in the audio device.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-samples-done"></a><h3>gst_ring_buffer_samples_done ()</h3>
<pre class="programlisting"><span class="returnvalue">guint64</span>             gst_ring_buffer_samples_done        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Get the number of samples that were processed by the ringbuffer
since it was last started. This does not include the number of samples not
yet processed (see <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-delay" title="gst_ring_buffer_delay ()"><code class="function">gst_ring_buffer_delay()</code></a>).
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to query</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>The number of samples processed by the ringbuffer.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-set-sample"></a><h3>gst_ring_buffer_set_sample ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gst_ring_buffer_set_sample          (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint64</span> sample</code></em>);</pre>
<p>
Make sure that the next sample written to the device is
accounted for as being the <em class="parameter"><code>sample</code></em> sample written to the
device. This value will be used in reporting the current
sample position of the ringbuffer.
</p>
<p>
This function will also clear the buffer with silence.
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to use</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>sample</code></em> :</span></p></td>
<td>the sample number to set</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-commit"></a><h3>gst_ring_buffer_commit ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>               gst_ring_buffer_commit              (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint64</span> sample</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> len</code></em>);</pre>
<p>
Same as <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-commit-full" title="gst_ring_buffer_commit_full ()"><code class="function">gst_ring_buffer_commit_full()</code></a> but with a in_samples and out_samples
equal to <em class="parameter"><code>len</code></em>, ignoring accum.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to commit</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>sample</code></em> :</span></p></td>
<td>the sample position of the data</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>data</code></em> :</span></p></td>
<td>the data to commit</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>len</code></em> :</span></p></td>
<td>the number of samples in the data to commit</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>The number of samples written to the ringbuffer or -1 on
error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-commit-full"></a><h3>gst_ring_buffer_commit_full ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>               gst_ring_buffer_commit_full         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint64</span> *sample</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> in_samples</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> out_samples</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *accum</code></em>);</pre>
<p>
Commit <em class="parameter"><code>in_samples</code></em> samples pointed to by <em class="parameter"><code>data</code></em> to the ringbuffer <em class="parameter"><code>buf</code></em>. 
</p>
<p>
<em class="parameter"><code>in_samples</code></em> and <em class="parameter"><code>out_samples</code></em> define the rate conversion to perform on the
samples in <em class="parameter"><code>data</code></em>. For negative rates, <em class="parameter"><code>out_samples</code></em> must be negative and
<em class="parameter"><code>in_samples</code></em> positive.
</p>
<p>
When <em class="parameter"><code>out_samples</code></em> is positive, the first sample will be written at position <em class="parameter"><code>sample</code></em>
in the ringbuffer. When <em class="parameter"><code>out_samples</code></em> is negative, the last sample will be written to
<em class="parameter"><code>sample</code></em> in reverse order.
</p>
<p>
<em class="parameter"><code>out_samples</code></em> does not need to be a multiple of the segment size of the ringbuffer
although it is recommended for optimal performance. 
</p>
<p>
<em class="parameter"><code>accum</code></em> will hold a temporary accumulator used in rate conversion and should be
set to 0 when this function is first called. In case the commit operation is
interrupted, one can resume the processing by passing the previously returned
<em class="parameter"><code>accum</code></em> value back to this function.
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to commit</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>sample</code></em> :</span></p></td>
<td>the sample position of the data</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>data</code></em> :</span></p></td>
<td>the data to commit</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>in_samples</code></em> :</span></p></td>
<td>the number of samples in the data to commit</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>out_samples</code></em> :</span></p></td>
<td>the number of samples to write to the ringbuffer</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>accum</code></em> :</span></p></td>
<td>accumulator for rate conversion.</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>The number of samples written to the ringbuffer or -1 on error. The
number of samples written can be less than <em class="parameter"><code>out_samples</code></em> when <em class="parameter"><code>buf</code></em> was interrupted
with a flush or stop.</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 0.10.11.</p>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-convert"></a><h3>gst_ring_buffer_convert ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_convert             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstFormat.html#GstFormat"><span class="type">GstFormat</span></a> src_fmt</code></em>,
                                                         <em class="parameter"><code><span class="type">gint64</span> src_val</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstFormat.html#GstFormat"><span class="type">GstFormat</span></a> dest_fmt</code></em>,
                                                         <em class="parameter"><code><span class="type">gint64</span> *dest_val</code></em>);</pre>
<p>
Convert <em class="parameter"><code>src_val</code></em> in <em class="parameter"><code>src_fmt</code></em> to the equivalent value in <em class="parameter"><code>dest_fmt</code></em>. The result
will be put in <em class="parameter"><code>dest_val</code></em>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>src_fmt</code></em> :</span></p></td>
<td>the source format</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>src_val</code></em> :</span></p></td>
<td>the source value</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>dest_fmt</code></em> :</span></p></td>
<td>the destination format</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>dest_val</code></em> :</span></p></td>
<td>a location to store the converted value</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the conversion succeeded.</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 0.10.22.</p>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-prepare-read"></a><h3>gst_ring_buffer_prepare_read ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_prepare_read        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *segment</code></em>,
                                                         <em class="parameter"><code><span class="type">guint8</span> **readptr</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *len</code></em>);</pre>
<p>
Returns a pointer to memory where the data from segment <em class="parameter"><code>segment</code></em>
can be found. This function is mostly used by subclasses.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to read from</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>segment</code></em> :</span></p></td>
<td>the segment to read</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>readptr</code></em> :</span></p></td>
<td>the pointer to the memory where samples can be read</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>len</code></em> :</span></p></td>
<td>the number of bytes to read</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>FALSE if the buffer is not started.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-read"></a><h3>gst_ring_buffer_read ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="returnvalue">guint</span></a>               gst_ring_buffer_read                (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><span class="type">guint64</span> sample</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guchar"><span class="type">guchar</span></a> *data</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> len</code></em>);</pre>
<p>
Read <em class="parameter"><code>len</code></em> samples from the ringbuffer into the memory pointed 
to by <em class="parameter"><code>data</code></em>.
The first sample should be read from position <em class="parameter"><code>sample</code></em> in
the ringbuffer.
</p>
<p>
<em class="parameter"><code>len</code></em> should not be a multiple of the segment size of the ringbuffer
although it is recommended.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to read from</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>sample</code></em> :</span></p></td>
<td>the sample position of the data</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>data</code></em> :</span></p></td>
<td>where the data should be read</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>len</code></em> :</span></p></td>
<td>the number of samples in data to read</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>The number of samples read from the ringbuffer or -1 on
error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-clear"></a><h3>gst_ring_buffer_clear ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gst_ring_buffer_clear               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> segment</code></em>);</pre>
<p>
Clear the given segment of the buffer with silence samples.
This function is used by subclasses.
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to clear</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>segment</code></em> :</span></p></td>
<td>the segment to clear</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-clear-all"></a><h3>gst_ring_buffer_clear_all ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gst_ring_buffer_clear_all           (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Fill the ringbuffer with silence.
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to clear</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-advance"></a><h3>gst_ring_buffer_advance ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gst_ring_buffer_advance             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#guint"><span class="type">guint</span></a> advance</code></em>);</pre>
<p>
Subclasses should call this function to notify the fact that 
<em class="parameter"><code>advance</code></em> segments are now processed by the device.
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to advance</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>advance</code></em> :</span></p></td>
<td>the number of segments written</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-close-device"></a><h3>gst_ring_buffer_close_device ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_close_device        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Close the audio device associated with the ring buffer. The ring buffer
should already have been released via <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#gst-ring-buffer-release" title="gst_ring_buffer_release ()"><code class="function">gst_ring_buffer_release()</code></a>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device could be closed, FALSE on error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-open-device"></a><h3>gst_ring_buffer_open_device ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_open_device         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Open the audio device associated with the ring buffer. Does not perform any
setup on the device. You must open the device before acquiring the ring
buffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device could be opened, FALSE on error.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-device-is-open"></a><h3>gst_ring_buffer_device_is_open ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_device_is_open      (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>);</pre>
<p>
Checks the status of the device associated with the ring buffer.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the device was open, FALSE if it was closed.
MT safe.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-may-start"></a><h3>gst_ring_buffer_may_start ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gst_ring_buffer_may_start           (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> allowed</code></em>);</pre>
<p>
Tell the ringbuffer that it is allowed to start playback when
the ringbuffer is filled with samples. 
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>allowed</code></em> :</span></p></td>
<td>the new value</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 0.10.6</p>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-parse-caps"></a><h3>gst_ring_buffer_parse_caps ()</h3>
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            gst_ring_buffer_parse_caps          (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBufferSpec" title="struct GstRingBufferSpec"><span class="type">GstRingBufferSpec</span></a> *spec</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a> *caps</code></em>);</pre>
<p>
Parse <em class="parameter"><code>caps</code></em> into <em class="parameter"><code>spec</code></em>.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>spec</code></em> :</span></p></td>
<td>a spec</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>caps</code></em> :</span></p></td>
<td>a <a href="/usr/share/gtk-doc/html/gstreamer-0.10/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>TRUE if the caps could be parsed.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gst-ring-buffer-set-flushing"></a><h3>gst_ring_buffer_set_flushing ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gst_ring_buffer_set_flushing        (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> *buf</code></em>,
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> flushing</code></em>);</pre>
<p>
Set the ringbuffer to flushing mode or normal mode.
</p>
<p>
MT safe.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>buf</code></em> :</span></p></td>
<td>the <a class="link" href="gst-plugins-base-libs-gstringbuffer.html#GstRingBuffer"><span class="type">GstRingBuffer</span></a> to flush</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>flushing</code></em> :</span></p></td>
<td>the new mode</td>
</tr>
</tbody>
</table></div>
</div>
</div>
<div class="refsect1">
<a name="gst-plugins-base-libs-gstringbuffer.see-also"></a><h2>See Also</h2>
<a class="link" href="gst-plugins-base-libs-gstbaseaudiosink.html#GstBaseAudioSink"><span class="type">GstBaseAudioSink</span></a>, <a class="link" href="gst-plugins-base-libs-gstaudiosink.html#GstAudioSink"><span class="type">GstAudioSink</span></a>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.18</div>
</body>
</html>