]> git.sesse.net Git - vlc/blobdiff - projects/activex/axvlc.idl
activex: implement JS Events
[vlc] / projects / activex / axvlc.idl
index 8944074ed98999b5560967e5f59e98c2f1193559..78defb74f9b09b6ff831cd20dfa25a7b8f0ff6b6 100644 (file)
@@ -2,6 +2,7 @@
  * axvlc.idl: ActiveX control for VLC\r
  *****************************************************************************\r
  * Copyright (C) 2006 the VideoLAN team\r
+ * Copyright (C) 2010 M2X BV\r
  *\r
  * Authors: Damien Fouilleul <Damien.Fouilleul@laposte.net>\r
  *          Jean-Paul Saman <jpsaman _at_ m2x _dot_ nl>\r
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.\r
  *****************************************************************************/\r
 \r
-//comments terminated by [t] are by tonsofpcs, regarding the string review.  April 02, 2006. [t]\r
-//Possibly change all instances of "the current playlist" to "the playlist" and "current playlist" to "the playlist" [t]\r
+// comments terminated by [t] are by tonsofpcs, regarding the string\r
+// review. April 02, 2006. [t]\r
+// Possibly change all instances of "the current playlist" to "the\r
+// playlist" and "current playlist" to "the playlist" [t]\r
 \r
 import "ocidl.idl";\r
 \r
@@ -37,10 +40,9 @@ library AXVLC
     interface IVLCControl;\r
     interface IVLCAudio;\r
     interface IVLCInput;\r
-    interface IVLCLog;\r
-    interface IVLCMessage;\r
-    interface IVLCMessageIterator;\r
-    interface IVLCMessages;\r
+    interface IVLCLogo;\r
+    interface IVLCDeinterlace;\r
+    interface IVLCMarquee;\r
     interface IVLCPlaylist;\r
     interface IVLCSubtitle;\r
     interface IVLCVideo;\r
@@ -128,13 +130,13 @@ library AXVLC
         HRESULT setVariable([in] BSTR name, [in] VARIANT value);\r
         [helpstring("Returns the value of a VLC variable.")]\r
         HRESULT getVariable([in] BSTR name, [out, retval] VARIANT *value);\r
-        [helpstring("Add an item to the playlist.")]\r
 \r
 /*\r
 ** use VARIANT rather than a SAFEARRAY as argument type\r
 ** for compatibility with some scripting language (JScript)\r
 */\r
 \r
+        [helpstring("Add an item to the playlist.")]\r
         HRESULT addTarget([in] BSTR uri, [in] VARIANT options, [in] enum VLCPlaylistMode mode, [in] int position);\r
         [propget, helpstring("Returns index of current item in playlist.")]\r
         HRESULT PlaylistIndex([out, retval] int* index);\r
@@ -166,6 +168,28 @@ library AXVLC
     const int DISPID_PauseEvent = 101;\r
     const int DISPID_StopEvent  = 102;\r
 \r
+    /* async events from libvlc */\r
+    const int DISPID_NothingSpecialEvent = 200;\r
+    const int DISPID_OpeningEvent = 201;\r
+    const int DISPID_BufferingEvent = 202;\r
+    const int DISPID_PlayingEvent = 203;\r
+    const int DISPID_PausedEvent = 204;\r
+    const int DISPID_ForwardEvent = 205;\r
+    const int DISPID_BackwardEvent = 206;\r
+    const int DISPID_EncounteredErrorEvent = 207;\r
+    const int DISPID_EndReachedEvent = 208;\r
+    const int DISPID_StoppedEvent = 209;\r
+\r
+    const int DISPID_TimeChangedEvent = 210;\r
+    const int DISPID_PositionChangedEvent = 211;\r
+    const int DISPID_SeekableChangedEvent = 212;\r
+    const int DISPID_PausableChangedEvent = 213;\r
+\r
+    const int DISPID_MouseButtonEvent = 214;\r
+    const int DISPID_MouseMovedEvent = 215;\r
+    const int DISPID_MouseClickedEvent = 216;\r
+    const int DISPID_MouseObjectEvent = 217;\r
+\r
     [\r
       uuid(DF48072F-5EF8-434e-9B40-E2F3AE759B5F),\r
       helpstring("Event interface for VLC control"),\r
@@ -180,6 +204,48 @@ library AXVLC
             void pause();\r
             [id(DISPID_StopEvent), helpstring("Stopped")]\r
             void stop();\r
+\r
+            /* asyn events from libvlc */\r
+            [id(DISPID_NothingSpecialEvent), helpstring("Idle state")]\r
+            void idle();\r
+            [id(DISPID_OpeningEvent), helpstring("Opening media")]\r
+            void opening();\r
+            [id(DISPID_BufferingEvent), helpstring("Buffering media")]\r
+            void buffering();\r
+            [id(DISPID_PlayingEvent), helpstring("Media is playing")]\r
+            void playing();\r
+            [id(DISPID_PausedEvent), helpstring("Media is paused")]\r
+            void paused();\r
+            [id(DISPID_ForwardEvent), helpstring("Forward playback")]\r
+            void forward();\r
+            [id(DISPID_BackwardEvent), helpstring("Backward playback")]\r
+            void backward();\r
+            [id(DISPID_EncounteredErrorEvent), helpstring("An error has been encountered")]\r
+            void error();\r
+            [id(DISPID_EndReachedEvent), helpstring("End of playback reached")]\r
+            void ended();\r
+            [id(DISPID_StoppedEvent), helpstring("Playback stopped")]\r
+            void stopped();\r
+\r
+            [id(DISPID_TimeChangedEvent), helpstring("Time changed")]\r
+            void TimeChanged([in] long time);\r
+            [id(DISPID_PositionChangedEvent), helpstring("Position changed")]\r
+            void PositionChanged([in] long position);\r
+            [id(DISPID_SeekableChangedEvent), helpstring("Seek changed")]\r
+            void SeekableChanged([in] VARIANT_BOOL seekable);\r
+            [id(DISPID_PausableChangedEvent), helpstring("Pause setting changed")]\r
+            void PausableChanged([in] VARIANT_BOOL pausable);\r
+\r
+            [id(DISPID_MouseButtonEvent), helpstring("Mouse button pressed")]\r
+            void MouseButton([in] VARIANT_BOOL btn_right, [in] VARIANT_BOOL btn_center,\r
+                [in] VARIANT_BOOL btn_left, [in] VARIANT_BOOL btn_wheel_up,\r
+                [in] VARIANT_BOOL bnt_wheel_down);\r
+            [id(DISPID_MouseMovedEvent), helpstring("Mouse moved")]\r
+            void MouseMoved([in] long x, [in] long y);\r
+            [id(DISPID_MouseClickedEvent), helpstring("Mouse clicked")]\r
+            void MouseClicked([in] VARIANT_BOOL clicked);\r
+            [id(DISPID_MouseObjectEvent), helpstring("Mouse selected holds object")]\r
+            void MouseObject([in] VARIANT_BOOL moved);\r
     };\r
 \r
     [\r
@@ -257,90 +323,6 @@ library AXVLC
         HRESULT hasVout([out, retval] VARIANT_BOOL* hasVout);\r
     };\r
 \r
-    [\r
-      odl,\r
-      uuid(9ED00AFA-7BCD-4FFF-8D48-7DD4DB2C800D),\r
-      helpstring("VLC Log Message"),\r
-      dual,\r
-      oleautomation\r
-    ]\r
-    interface IVLCMessage: IDispatch\r
-    {\r
-        [id(DISPID_VALUE), propget]\r
-        HRESULT _Value([out, retval] VARIANT* message);\r
-\r
-        [propget, helpstring("Returns message severity.")]\r
-        HRESULT severity([out, retval] long* level);\r
-\r
-        [propget, helpstring("Returns message issuer type.")]\r
-        HRESULT type([out, retval] BSTR* type);\r
-\r
-        [propget, helpstring("Returns message issuer name.")]\r
-        HRESULT name([out, retval] BSTR* name);\r
-\r
-        [propget, helpstring("Returns message header.")]\r
-        HRESULT header([out, retval] BSTR* header);\r
-\r
-        [propget, helpstring("Returns message content.")]\r
-        HRESULT message([out, retval] BSTR* message);\r
-    };\r
-\r
-    [\r
-      odl,\r
-      uuid(15179CD8-CC12-4242-A58E-E412217FF343),\r
-      helpstring("VLC Log iterator"),\r
-      dual,\r
-      oleautomation\r
-    ]\r
-    interface IVLCMessageIterator : IDispatch\r
-    {\r
-        [propget, helpstring("Returns whether a message is available.")]\r
-        HRESULT hasNext([out, retval] VARIANT_BOOL* hasNext);\r
-\r
-        [helpstring("Returns next message.")]\r
-        HRESULT next([out, retval] IVLCMessage** msg);\r
-    };\r
-\r
-    [\r
-      odl,\r
-      uuid(6C5CE55D-2D6C-4AAD-8299-C62D2371F106),\r
-      helpstring("VLC Log Messages Collection."),\r
-      dual,\r
-      oleautomation\r
-    ]\r
-    interface IVLCMessages : IDispatch\r
-    {\r
-        [id(DISPID_NEWENUM), propget]\r
-        HRESULT _NewEnum([out, retval] IUnknown** _NewEnum);\r
-\r
-        [helpstring("Clear all messages from log.")]\r
-        HRESULT clear();\r
-\r
-        [propget, helpstring("Returns the number of messages.")]\r
-        HRESULT count([out, retval] long* count);\r
-\r
-        [helpstring("Returns an iterator for messages in log")]\r
-        HRESULT iterator([out, retval] IVLCMessageIterator** iter);\r
-    };\r
-\r
-    [\r
-      odl,\r
-      uuid(8E3BC3D9-62E9-48FB-8A6D-993F9ABC4A0A),\r
-      helpstring("VLC Log APIs"),\r
-      dual,\r
-      oleautomation\r
-    ]\r
-    interface IVLCLog : IDispatch\r
-    {\r
-        [propget, helpstring("Returns messages in log")]\r
-        HRESULT messages([out, retval] IVLCMessages** iter);\r
-\r
-        [propget, helpstring("Returns/Sets the log versbosity level.")]\r
-        HRESULT verbosity([out, retval] long* level);\r
-        [propput, helpstring("Returns/Sets the log versbosity level.")]\r
-        HRESULT verbosity([in] long level);\r
-    };\r
-\r
     [\r
       odl,\r
       uuid(FD37FE32-82BC-4A25-B056-315F4DBB194D),\r
@@ -426,6 +408,122 @@ library AXVLC
         HRESULT description([in] long nameID, [out, retval] BSTR* name);\r
     };\r
 \r
+    [\r
+      odl,\r
+      uuid(8D076AD6-9B6F-4150-A0FD-5D7E8C8CB02C),\r
+      helpstring("VLC Marquee Filter"),\r
+      dual,\r
+      oleautomation\r
+    ]\r
+    interface IVLCMarquee : IDispatch\r
+    {\r
+        [helpstring("enable Marquee Filter.")]\r
+        HRESULT enable();\r
+        [helpstring("disable Marquee Filter.")]\r
+        HRESULT disable();\r
+\r
+        [propget, helpstring("Retrieve marquee text.")]\r
+        HRESULT text([out, retval] BSTR* val);\r
+        [propput, helpstring("Change marquee text.")]\r
+        HRESULT text([in] BSTR val);\r
+\r
+        [propget, helpstring("Retrieve text color.")]\r
+        HRESULT color([out, retval] LONG* val);\r
+        [propput, helpstring("Change text color.")]\r
+        HRESULT color([in] LONG val);\r
+        [propget, helpstring("Retrieve text opacity.")]\r
+        HRESULT opacity([out, retval] LONG* val);\r
+        [propput, helpstring("Set text opacity (0=transparent, 255=opaque).")]\r
+        HRESULT opacity([in] LONG val);\r
+        [propget, helpstring("Retrieve text position.")]\r
+        HRESULT position([out, retval] BSTR* val);\r
+        [propput, helpstring("Text positioning relative to: center, left, right, top, bottom, top-left, top-right, bottom-left, bottom-right.")]\r
+        HRESULT position([in] BSTR val);\r
+        [propget, helpstring("Retrieve text refresh time.")]\r
+        HRESULT refresh([out, retval] LONG* val);\r
+        [propput, helpstring("Set text refresh time.")]\r
+        HRESULT refresh([in] LONG val);\r
+        [propget, helpstring("Retrieve text size.")]\r
+        HRESULT size([out, retval] LONG* val);\r
+        [propput, helpstring("Set text size.")]\r
+        HRESULT size([in] LONG val);\r
+        [propget, helpstring("Retrieve timeout.")]\r
+        HRESULT timeout([out, retval] LONG* val);\r
+        [propput, helpstring("Change timeout.")]\r
+        HRESULT timeout([in] LONG val);\r
+        [propget, helpstring("Retrieve text abcissa.")]\r
+        HRESULT x([out, retval] LONG* val);\r
+        [propput, helpstring("Change text abcissa.")]\r
+        HRESULT x([in] LONG val);\r
+        [propget, helpstring("Retrieve text ordinate.")]\r
+        HRESULT y([out, retval] LONG* val);\r
+        [propput, helpstring("Change text ordinate.")]\r
+        HRESULT y([in] LONG val);\r
+    };\r
+\r
+    [\r
+      odl,\r
+      uuid(8a4a20c2-93f3-44e8-8644-beb2e3487e84),\r
+      helpstring("VLC Logo Filter"),\r
+      dual,\r
+      oleautomation\r
+    ]\r
+    interface IVLCLogo : IDispatch\r
+    {\r
+        [helpstring("Enable the logo filter.")]\r
+        HRESULT enable();\r
+        [helpstring("Disable the logo filter.")]\r
+        HRESULT disable();\r
+\r
+        [helpstring("specify input file[[,delay],alpha].")]\r
+        HRESULT file([in] BSTR fname);\r
+\r
+        [propget, helpstring("")]\r
+        HRESULT delay([out, retval] long* val);\r
+        [propput, helpstring("Set delay-to-next-picture in miliseconds.")]\r
+        HRESULT delay([in] long val);\r
+\r
+        [propget, helpstring("")]\r
+        HRESULT repeat([out, retval] long* val);\r
+        [propput, helpstring("Repeat: -1 continuous (default), 0 no repeat, ....")]\r
+        HRESULT repeat([in] long val);\r
+\r
+        [propget, helpstring("Returns the `global' alpha value.")]\r
+        HRESULT opacity([out, retval] long* val);\r
+        [propput, helpstring("Alpha value: 0 opaque to 255 fully transparent")]\r
+        HRESULT opacity([in] long val);\r
+\r
+        [propget, helpstring("Retrieve picture position.")]\r
+        HRESULT position([out, retval] BSTR* val);\r
+        [propput, helpstring("Picture positioning relative to: center, left, right, top, bottom, top-left, top-right, bottom-left, bottom-right.")]\r
+        HRESULT position([in] BSTR val);\r
+\r
+        [propget, helpstring("Picture x offset.")]\r
+        HRESULT x([out, retval] long* val);\r
+        [propput, helpstring("Picture x offset.")]\r
+        HRESULT x([in] long val);\r
+        [propget, helpstring("Picture y offset.")]\r
+        HRESULT y([out, retval] long* val);\r
+        [propput, helpstring("Picture y offset.")]\r
+        HRESULT y([in] long val);\r
+\r
+    };\r
+    [\r
+      odl,\r
+      uuid(bc97469f-cb11-4037-8dce-5fc9f5f85307),\r
+      helpstring("VLC Deinterlace Filter"),\r
+      dual,\r
+      oleautomation\r
+    ]\r
+    interface IVLCDeinterlace : IDispatch\r
+    {\r
+        [helpstring("Enable deinterlace filter and set method.")]\r
+        HRESULT enable([in] BSTR mode);\r
+        [helpstring("Disable deinterlace filter.")]\r
+        HRESULT disable();\r
+\r
+    };\r
+\r
     [\r
       odl,\r
       uuid(0AAEDF0B-D333-4B27-A0C6-BBF31413A42E),\r
@@ -475,6 +573,15 @@ library AXVLC
 \r
         [helpstring("toggle teletext transparent state.")]\r
         HRESULT toggleTeletext();\r
+\r
+        [propget, helpstring("Returns the marquee object.")]\r
+        HRESULT marquee([out, retval] IVLCMarquee** obj);\r
+\r
+        [propget, helpstring("Returns the logo object.")]\r
+        HRESULT logo([out, retval] IVLCLogo** obj);\r
+\r
+        [propget, helpstring("Returns the logo object.")]\r
+        HRESULT deinterlace([out, retval] IVLCDeinterlace** obj);\r
     };\r
 \r
     [\r
@@ -545,9 +652,6 @@ library AXVLC
         [propget, helpstring("Returns the audio object.")]\r
         HRESULT input([out, retval] IVLCInput** obj);\r
 \r
-        [propget, helpstring("Returns the log object.")]\r
-        HRESULT log([out, retval] IVLCLog** obj);\r
-\r
         [propget, helpstring("Returns the playlist object.")]\r
         HRESULT playlist([out, retval] IVLCPlaylist** obj);\r
 \r
@@ -579,5 +683,6 @@ library AXVLC
     {\r
         [default] interface IVLCControl2;\r
         interface IVLCControl;\r
+        [default, source] dispinterface DVLCEvents;\r
     };\r
 };\r