video-set-format.rst 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. .. -*- coding: utf-8; mode: rst -*-
  2. .. _VIDEO_SET_FORMAT:
  3. ================
  4. VIDEO_SET_FORMAT
  5. ================
  6. Name
  7. ----
  8. VIDEO_SET_FORMAT
  9. .. attention:: This ioctl is deprecated.
  10. Synopsis
  11. --------
  12. .. c:function:: int ioctl(fd, VIDEO_SET_FORMAT, video_format_t format)
  13. :name: VIDEO_SET_FORMAT
  14. Arguments
  15. ---------
  16. .. flat-table::
  17. :header-rows: 0
  18. :stub-columns: 0
  19. - .. row 1
  20. - int fd
  21. - File descriptor returned by a previous call to open().
  22. - .. row 2
  23. - int request
  24. - Equals VIDEO_SET_FORMAT for this command.
  25. - .. row 3
  26. - video_format_t format
  27. - video format of TV as defined in section ??.
  28. Description
  29. -----------
  30. This ioctl sets the screen format (aspect ratio) of the connected output
  31. device (TV) so that the output of the decoder can be adjusted
  32. accordingly.
  33. .. c:type:: video_format_t
  34. .. code-block:: c
  35. typedef enum {
  36. VIDEO_FORMAT_4_3, /* Select 4:3 format */
  37. VIDEO_FORMAT_16_9, /* Select 16:9 format. */
  38. VIDEO_FORMAT_221_1 /* 2.21:1 */
  39. } video_format_t;
  40. Return Value
  41. ------------
  42. On success 0 is returned, on error -1 and the ``errno`` variable is set
  43. appropriately. The generic error codes are described at the
  44. :ref:`Generic Error Codes <gen-errors>` chapter.
  45. .. flat-table::
  46. :header-rows: 0
  47. :stub-columns: 0
  48. - .. row 1
  49. - ``EINVAL``
  50. - format is not a valid video format.