diff options
Diffstat (limited to 'include/linux/videodev2.h')
| -rw-r--r-- | include/linux/videodev2.h | 92 |
1 files changed, 69 insertions, 23 deletions
diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index fca24cc50436..225560c1a10f 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h | |||
| @@ -759,10 +759,10 @@ typedef __u64 v4l2_std_id; | |||
| 759 | #define V4L2_STD_PAL_Nc ((v4l2_std_id)0x00000400) | 759 | #define V4L2_STD_PAL_Nc ((v4l2_std_id)0x00000400) |
| 760 | #define V4L2_STD_PAL_60 ((v4l2_std_id)0x00000800) | 760 | #define V4L2_STD_PAL_60 ((v4l2_std_id)0x00000800) |
| 761 | 761 | ||
| 762 | #define V4L2_STD_NTSC_M ((v4l2_std_id)0x00001000) | 762 | #define V4L2_STD_NTSC_M ((v4l2_std_id)0x00001000) /* BTSC */ |
| 763 | #define V4L2_STD_NTSC_M_JP ((v4l2_std_id)0x00002000) | 763 | #define V4L2_STD_NTSC_M_JP ((v4l2_std_id)0x00002000) /* EIA-J */ |
| 764 | #define V4L2_STD_NTSC_443 ((v4l2_std_id)0x00004000) | 764 | #define V4L2_STD_NTSC_443 ((v4l2_std_id)0x00004000) |
| 765 | #define V4L2_STD_NTSC_M_KR ((v4l2_std_id)0x00008000) | 765 | #define V4L2_STD_NTSC_M_KR ((v4l2_std_id)0x00008000) /* FM A2 */ |
| 766 | 766 | ||
| 767 | #define V4L2_STD_SECAM_B ((v4l2_std_id)0x00010000) | 767 | #define V4L2_STD_SECAM_B ((v4l2_std_id)0x00010000) |
| 768 | #define V4L2_STD_SECAM_D ((v4l2_std_id)0x00020000) | 768 | #define V4L2_STD_SECAM_D ((v4l2_std_id)0x00020000) |
| @@ -786,47 +786,86 @@ typedef __u64 v4l2_std_id; | |||
| 786 | v4l2-common.c should be fixed. | 786 | v4l2-common.c should be fixed. |
| 787 | */ | 787 | */ |
| 788 | 788 | ||
| 789 | /* some merged standards */ | 789 | /* |
| 790 | #define V4L2_STD_MN (V4L2_STD_PAL_M|V4L2_STD_PAL_N|V4L2_STD_PAL_Nc|V4L2_STD_NTSC) | 790 | * Some macros to merge video standards in order to make live easier for the |
| 791 | #define V4L2_STD_B (V4L2_STD_PAL_B|V4L2_STD_PAL_B1|V4L2_STD_SECAM_B) | 791 | * drivers and V4L2 applications |
| 792 | #define V4L2_STD_GH (V4L2_STD_PAL_G|V4L2_STD_PAL_H|V4L2_STD_SECAM_G|V4L2_STD_SECAM_H) | 792 | */ |
| 793 | #define V4L2_STD_DK (V4L2_STD_PAL_DK|V4L2_STD_SECAM_DK) | ||
| 794 | 793 | ||
| 795 | /* some common needed stuff */ | 794 | /* |
| 796 | #define V4L2_STD_PAL_BG (V4L2_STD_PAL_B |\ | 795 | * "Common" NTSC/M - It should be noticed that V4L2_STD_NTSC_443 is |
| 797 | V4L2_STD_PAL_B1 |\ | 796 | * Missing here. |
| 798 | V4L2_STD_PAL_G) | 797 | */ |
| 799 | #define V4L2_STD_PAL_DK (V4L2_STD_PAL_D |\ | ||
| 800 | V4L2_STD_PAL_D1 |\ | ||
| 801 | V4L2_STD_PAL_K) | ||
| 802 | #define V4L2_STD_PAL (V4L2_STD_PAL_BG |\ | ||
| 803 | V4L2_STD_PAL_DK |\ | ||
| 804 | V4L2_STD_PAL_H |\ | ||
| 805 | V4L2_STD_PAL_I) | ||
| 806 | #define V4L2_STD_NTSC (V4L2_STD_NTSC_M |\ | 798 | #define V4L2_STD_NTSC (V4L2_STD_NTSC_M |\ |
| 807 | V4L2_STD_NTSC_M_JP |\ | 799 | V4L2_STD_NTSC_M_JP |\ |
| 808 | V4L2_STD_NTSC_M_KR) | 800 | V4L2_STD_NTSC_M_KR) |
| 801 | /* Secam macros */ | ||
| 809 | #define V4L2_STD_SECAM_DK (V4L2_STD_SECAM_D |\ | 802 | #define V4L2_STD_SECAM_DK (V4L2_STD_SECAM_D |\ |
| 810 | V4L2_STD_SECAM_K |\ | 803 | V4L2_STD_SECAM_K |\ |
| 811 | V4L2_STD_SECAM_K1) | 804 | V4L2_STD_SECAM_K1) |
| 805 | /* All Secam Standards */ | ||
| 812 | #define V4L2_STD_SECAM (V4L2_STD_SECAM_B |\ | 806 | #define V4L2_STD_SECAM (V4L2_STD_SECAM_B |\ |
| 813 | V4L2_STD_SECAM_G |\ | 807 | V4L2_STD_SECAM_G |\ |
| 814 | V4L2_STD_SECAM_H |\ | 808 | V4L2_STD_SECAM_H |\ |
| 815 | V4L2_STD_SECAM_DK |\ | 809 | V4L2_STD_SECAM_DK |\ |
| 816 | V4L2_STD_SECAM_L |\ | 810 | V4L2_STD_SECAM_L |\ |
| 817 | V4L2_STD_SECAM_LC) | 811 | V4L2_STD_SECAM_LC) |
| 812 | /* PAL macros */ | ||
| 813 | #define V4L2_STD_PAL_BG (V4L2_STD_PAL_B |\ | ||
| 814 | V4L2_STD_PAL_B1 |\ | ||
| 815 | V4L2_STD_PAL_G) | ||
| 816 | #define V4L2_STD_PAL_DK (V4L2_STD_PAL_D |\ | ||
| 817 | V4L2_STD_PAL_D1 |\ | ||
| 818 | V4L2_STD_PAL_K) | ||
| 819 | /* | ||
| 820 | * "Common" PAL - This macro is there to be compatible with the old | ||
| 821 | * V4L1 concept of "PAL": /BGDKHI. | ||
| 822 | * Several PAL standards are mising here: /M, /N and /Nc | ||
| 823 | */ | ||
| 824 | #define V4L2_STD_PAL (V4L2_STD_PAL_BG |\ | ||
| 825 | V4L2_STD_PAL_DK |\ | ||
| 826 | V4L2_STD_PAL_H |\ | ||
| 827 | V4L2_STD_PAL_I) | ||
| 828 | /* Chroma "agnostic" standards */ | ||
| 829 | #define V4L2_STD_B (V4L2_STD_PAL_B |\ | ||
| 830 | V4L2_STD_PAL_B1 |\ | ||
| 831 | V4L2_STD_SECAM_B) | ||
| 832 | #define V4L2_STD_G (V4L2_STD_PAL_G |\ | ||
| 833 | V4L2_STD_SECAM_G) | ||
| 834 | #define V4L2_STD_H (V4L2_STD_PAL_H |\ | ||
| 835 | V4L2_STD_SECAM_H) | ||
| 836 | #define V4L2_STD_L (V4L2_STD_SECAM_L |\ | ||
| 837 | V4L2_STD_SECAM_LC) | ||
| 838 | #define V4L2_STD_GH (V4L2_STD_G |\ | ||
| 839 | V4L2_STD_H) | ||
| 840 | #define V4L2_STD_DK (V4L2_STD_PAL_DK |\ | ||
| 841 | V4L2_STD_SECAM_DK) | ||
| 842 | #define V4L2_STD_BG (V4L2_STD_B |\ | ||
| 843 | V4L2_STD_G) | ||
| 844 | #define V4L2_STD_MN (V4L2_STD_PAL_M |\ | ||
| 845 | V4L2_STD_PAL_N |\ | ||
| 846 | V4L2_STD_PAL_Nc |\ | ||
| 847 | V4L2_STD_NTSC) | ||
| 848 | |||
| 849 | /* Standards where MTS/BTSC stereo could be found */ | ||
| 850 | #define V4L2_STD_MTS (V4L2_STD_NTSC_M |\ | ||
| 851 | V4L2_STD_PAL_M |\ | ||
| 852 | V4L2_STD_PAL_N |\ | ||
| 853 | V4L2_STD_PAL_Nc) | ||
| 818 | 854 | ||
| 855 | /* Standards for Countries with 60Hz Line frequency */ | ||
| 819 | #define V4L2_STD_525_60 (V4L2_STD_PAL_M |\ | 856 | #define V4L2_STD_525_60 (V4L2_STD_PAL_M |\ |
| 820 | V4L2_STD_PAL_60 |\ | 857 | V4L2_STD_PAL_60 |\ |
| 821 | V4L2_STD_NTSC |\ | 858 | V4L2_STD_NTSC |\ |
| 822 | V4L2_STD_NTSC_443) | 859 | V4L2_STD_NTSC_443) |
| 860 | /* Standards for Countries with 50Hz Line frequency */ | ||
| 823 | #define V4L2_STD_625_50 (V4L2_STD_PAL |\ | 861 | #define V4L2_STD_625_50 (V4L2_STD_PAL |\ |
| 824 | V4L2_STD_PAL_N |\ | 862 | V4L2_STD_PAL_N |\ |
| 825 | V4L2_STD_PAL_Nc |\ | 863 | V4L2_STD_PAL_Nc |\ |
| 826 | V4L2_STD_SECAM) | 864 | V4L2_STD_SECAM) |
| 865 | |||
| 827 | #define V4L2_STD_ATSC (V4L2_STD_ATSC_8_VSB |\ | 866 | #define V4L2_STD_ATSC (V4L2_STD_ATSC_8_VSB |\ |
| 828 | V4L2_STD_ATSC_16_VSB) | 867 | V4L2_STD_ATSC_16_VSB) |
| 829 | 868 | /* Macros with none and all analog standards */ | |
| 830 | #define V4L2_STD_UNKNOWN 0 | 869 | #define V4L2_STD_UNKNOWN 0 |
| 831 | #define V4L2_STD_ALL (V4L2_STD_525_60 |\ | 870 | #define V4L2_STD_ALL (V4L2_STD_525_60 |\ |
| 832 | V4L2_STD_625_50) | 871 | V4L2_STD_625_50) |
| @@ -1082,6 +1121,7 @@ struct v4l2_querymenu { | |||
| 1082 | #define V4L2_CTRL_FLAG_INACTIVE 0x0010 | 1121 | #define V4L2_CTRL_FLAG_INACTIVE 0x0010 |
| 1083 | #define V4L2_CTRL_FLAG_SLIDER 0x0020 | 1122 | #define V4L2_CTRL_FLAG_SLIDER 0x0020 |
| 1084 | #define V4L2_CTRL_FLAG_WRITE_ONLY 0x0040 | 1123 | #define V4L2_CTRL_FLAG_WRITE_ONLY 0x0040 |
| 1124 | #define V4L2_CTRL_FLAG_VOLATILE 0x0080 | ||
| 1085 | 1125 | ||
| 1086 | /* Query flag, to be ORed with the control ID */ | 1126 | /* Query flag, to be ORed with the control ID */ |
| 1087 | #define V4L2_CTRL_FLAG_NEXT_CTRL 0x80000000 | 1127 | #define V4L2_CTRL_FLAG_NEXT_CTRL 0x80000000 |
| @@ -2006,6 +2046,7 @@ struct v4l2_streamparm { | |||
| 2006 | #define V4L2_EVENT_VSYNC 1 | 2046 | #define V4L2_EVENT_VSYNC 1 |
| 2007 | #define V4L2_EVENT_EOS 2 | 2047 | #define V4L2_EVENT_EOS 2 |
| 2008 | #define V4L2_EVENT_CTRL 3 | 2048 | #define V4L2_EVENT_CTRL 3 |
| 2049 | #define V4L2_EVENT_FRAME_SYNC 4 | ||
| 2009 | #define V4L2_EVENT_PRIVATE_START 0x08000000 | 2050 | #define V4L2_EVENT_PRIVATE_START 0x08000000 |
| 2010 | 2051 | ||
| 2011 | /* Payload for V4L2_EVENT_VSYNC */ | 2052 | /* Payload for V4L2_EVENT_VSYNC */ |
| @@ -2032,12 +2073,17 @@ struct v4l2_event_ctrl { | |||
| 2032 | __s32 default_value; | 2073 | __s32 default_value; |
| 2033 | }; | 2074 | }; |
| 2034 | 2075 | ||
| 2076 | struct v4l2_event_frame_sync { | ||
| 2077 | __u32 frame_sequence; | ||
| 2078 | }; | ||
| 2079 | |||
| 2035 | struct v4l2_event { | 2080 | struct v4l2_event { |
| 2036 | __u32 type; | 2081 | __u32 type; |
| 2037 | union { | 2082 | union { |
| 2038 | struct v4l2_event_vsync vsync; | 2083 | struct v4l2_event_vsync vsync; |
| 2039 | struct v4l2_event_ctrl ctrl; | 2084 | struct v4l2_event_ctrl ctrl; |
| 2040 | __u8 data[64]; | 2085 | struct v4l2_event_frame_sync frame_sync; |
| 2086 | __u8 data[64]; | ||
| 2041 | } u; | 2087 | } u; |
| 2042 | __u32 pending; | 2088 | __u32 pending; |
| 2043 | __u32 sequence; | 2089 | __u32 sequence; |
