summaryrefslogtreecommitdiff
path: root/include/vdr-xineliboutput/service_pip.h
blob: ee168fcf9f2df04f2c3fc080c65ec099ffb3a565 (plain)
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
/*
 * vdr-xineliboutput/service_pip.h: xineliboutput Picture-In-Picture service interface
 *
 * See the main source file 'xineliboutput.c' for copyright information and
 * how to reach the author.
 *
 * $Id: service_pip.h,v 1.1 2010-03-12 21:15:05 phintuka Exp $
 *
 */

#ifndef VDR_XINELIBOUTPUT_SERVICE_PIP_H
#define VDR_XINELIBOUTPUT_SERVICE_PIP_H

/*
 * Example:
 *
 * cXineliboutputPipService *pip_if;
 *
 * if (Plugin->Service(XINELIBOUTPUT_SERVICE_PIP_ID, &pip_if)) {
 *   while(...)
 *     pip_if->PlayTs(...);
 *   delete pip_if;
 * }
 *
 */

#define XINELIBOUTPUT_SERVICE_PIP_ID      "Xineliboutput_Pip_Open"

#define XINELIBOUTPUT_SERVICE_PIP_VERSION 0x0100

class cXineliboutputPipService {

  public:

    /* Set location and size (in % of full screen)
     * Example:
     *   Blend PIP picture to left-top corner, resize to 20% of full screen:
     *     SetPosition(5, 5, 20, 20);
     */
    virtual void SetPosition(uint X, uint Y, uint W, uint H) = 0;

    /* PIP input: single MPEG-TS video packet */
    virtual int  PlayTs(const uint8_t *Data) = 0;

    virtual ~cXineliboutputPipService() {};
};


#endif /* VDR_XINELIBOUTPUT_SERVICE_PIP_H */