gstmeta.inc 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. {
  2. /* GStreamer
  3. * Copyright (C) 2009 Wim Taymans <[email protected]>
  4. *
  5. * gstmeta.h: Header for Metadata structures
  6. *
  7. * This library is free software; you can redistribute it and/or
  8. * modify it under the terms of the GNU Library General Public
  9. * License as published by the Free Software Foundation; either
  10. * version 2 of the License, or (at your option) any later version.
  11. *
  12. * This library is distributed in the hope that it will be useful,
  13. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  15. * Library General Public License for more details.
  16. *
  17. * You should have received a copy of the GNU Library General Public
  18. * License along with this library; if not, write to the
  19. * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
  20. * Boston, MA 02110-1301, USA.
  21. */
  22. }
  23. Type
  24. P_GstMetaInfo = ^T_GstMetaInfo;
  25. PGstMeta = ^TGstMeta;
  26. PPGstMeta = ^PGstMeta;
  27. PGstMetaInfo = ^TGstMetaInfo;
  28. PGstMetaTransformCopy = ^TGstMetaTransformCopy;
  29. {$IFDEF FPC}
  30. {$PACKRECORDS C}
  31. {$ENDIF}
  32. TGstMetaInitFunction = function (meta:PGstMeta; params:Tgpointer; buffer:PGstBuffer):Tgboolean;cdecl;
  33. TGstMetaFreeFunction = procedure (meta:PGstMeta; buffer:PGstBuffer);cdecl;
  34. TGstMetaTransformCopy = record
  35. region : Tgboolean;
  36. offset : Tgsize;
  37. size : Tgsize;
  38. end;
  39. TGstMetaTransformFunction = function (transbuf:PGstBuffer; meta:PGstMeta; buffer:PGstBuffer; _type:TGQuark; data:Tgpointer):Tgboolean;cdecl;
  40. T_GstMetaInfo = record
  41. api : TGType;
  42. _type : TGType;
  43. size : Tgsize;
  44. init_func : TGstMetaInitFunction;
  45. free_func : TGstMetaFreeFunction;
  46. transform_func : TGstMetaTransformFunction;
  47. end;
  48. TGstMetaInfo = T_GstMetaInfo;
  49. TGstMetaFlags = (
  50. GST_META_FLAG_NONE := 0,
  51. GST_META_FLAG_READONLY := 1 shl 0,
  52. GST_META_FLAG_POOLED := 1 shl 1,
  53. GST_META_FLAG_LOCKED := 1 shl 2,
  54. GST_META_FLAG_LAST := 1 shl 16);
  55. P_GstMeta = ^T_GstMeta;
  56. PGstMetaFlags = ^TGstMetaFlags;
  57. T_GstMeta = record
  58. flags : TGstMetaFlags;
  59. info : PGstMetaInfo;
  60. end;
  61. TGstMeta = T_GstMeta;
  62. var
  63. _gst_meta_transform_copy : TGQuark;cvar;external;
  64. (* Const before type ignored *)
  65. (* Const before type ignored *)
  66. function gst_meta_api_type_register(api:Pgchar; tags:PPgchar):TGType;cdecl;external gstreamerlib name 'gst_meta_api_type_register';
  67. function gst_meta_api_type_has_tag(api:TGType; tag:TGQuark):Tgboolean;cdecl;external gstreamerlib name 'gst_meta_api_type_has_tag';
  68. (* Const before type ignored *)
  69. (* Const before type ignored *)
  70. function gst_meta_register(api:TGType; impl:Pgchar; size:Tgsize; init_func:TGstMetaInitFunction; free_func:TGstMetaFreeFunction;
  71. transform_func:TGstMetaTransformFunction):PGstMetaInfo;cdecl;external gstreamerlib name 'gst_meta_register';
  72. (* Const before type ignored *)
  73. (* Const before type ignored *)
  74. function gst_meta_get_info(impl:Pgchar):PGstMetaInfo;cdecl;external gstreamerlib name 'gst_meta_get_info';
  75. (* Const before type ignored *)
  76. (* Const before declarator ignored *)
  77. function gst_meta_api_type_get_tags(api:TGType):PPgchar;cdecl;external gstreamerlib name 'gst_meta_api_type_get_tags';
  78. (* Const before type ignored *)
  79. function gst_meta_get_seqnum(meta:PGstMeta):Tguint64;cdecl;external gstreamerlib name 'gst_meta_get_seqnum';
  80. (* Const before type ignored *)
  81. (* Const before type ignored *)
  82. function gst_meta_compare_seqnum(meta1:PGstMeta; meta2:PGstMeta):Tgint;cdecl;external gstreamerlib name 'gst_meta_compare_seqnum';
  83. var
  84. _gst_meta_tag_memory : TGQuark;cvar;external;