Adtec API Help

# ONSCREENDISPLAY OSD OD ## Description:
      Manages decoder's On-Screen Display.  If the OSD command is issued without an argued option,
      the current OSD status will be displayed.

      The currently supported OSD graphic formats are BMP, JPEG, PNG and GIF.  Please refer to
      your manual for details on accepted format options.

      The OSD command supports many options for specifying the position and size of the image,
      including +/- arguments, percentage arguments and 'forced' aspect ratio sizing if the
      OSDTEMPLATE is not active.

      The LOAD feature will prepare the OSD for display in the background.  If an OSD is
      currently displayed, the LOAD will not override the current image until a new DISPLAY command
      is issued.

      The OSD system supports a 'template', which allows multiple images to be loaded and
      displayed at the same time, along with CRAWL and TEXT regions.  The OSDTEMPLATE command
      is used to set the template parameters.  The CRAWL region will render a graphic from
      a text string found in a text file and 'crawl' the rendered text across the screen.  See
      the CRAWL description for information on available CRAWL options.  The TEXT region will
      display preformatted information, such as date and time, and will update the TEXT region
      periodically.  See the TEXT description for information on available TEXT options.

      The REGION parameter is used when templates are active to individually control images, crawl
      and text.  If the region index is not argued, the OSD command will default to using region 0.

      A single CRAWL or TEXT may be displayed anywhere on the screen as a single OSD image if
      the template is active.  Since all parameters for the OSD CRAWL and OSD TEXT commands can be
      specified, the result is the ability to show a CRAWL or TEXT anywhere on the screen, using
      custom X, Y, WIDTH and HEIGHT.  If the background color is set to 00000000, the rendered text
      will have a fully transparent background.

      Note: OSD based DECODECLOSEDCAPTION modes and OSD cannot be used at the same time.
            If DECODECLOSEDCAPTION is set to an OSD based mode , then the OSD and OST
            command options will not be activated. The API will return an error message
            "OSD based closed caption is active, cannot run OSD functions" in this case.
            The terse form of the error message is 568.
## Form:
    LOAD: Loads and verifies an OSD image from disk.  This does not display the image.
      Command Handler: DCMD
      ONSCREENDISPLAY|OSD|OD [REGION] L <FILENAME>
      Argument List:
      Argument      Description
      REGION        (optional) If argued specify which region to change
                               This defaults to region 0 (the first region)
      FILENAME      File name of OSD image file to load. Loaded files have adjustable positioning
                    sizing and blending.

    DISPLAY: Sets positioning , size, and blend values, and activates the previously loaded
    image display.  If an OSDTEMPLATE is active, the X, Y, PERCENT, SCALE WIDTH and SCALE HEIGHT
    parameters may be omitted, and will be ignored if argued
      ONSCREENDISPLAY|OSD|OD [REGION] D [SET X] [SET Y] [PERCENT] [[SCALE WIDTH] [SCALE HEIGHT]]
      Argument List:
      Argument      Description
      REGION        (optional) If argued specify which region to change
                               This defaults to region 0 (the first region)
      ORIGIN X      Sets X position of image. Value must fit the current video
                    display resolution.
                    Accepts offsets (+/-) and absolutes (no sign).  L, C,
                    and R (Left, Center, Right) may also be argued to
                    automatically place the X position.  An '*' may be argued to
                    keep the existing value, if changing other parameters.
                    Note: ORIGIN X and ORIGIN Y denote the upper left corner of the image.
                    Note: Not used if OSDTEMPLATE is active.
      ORIGN Y       Sets Y position of image. Value must fit the current video
                    display resolution.
                    Accepts offsets (+/-) and absolutes (no sign).  T, C,
                    and B (Top, Center, Bottom) may also be argued to
                    automatically place the Y position.  An '*' may be argued to
                    keep the existing value, if changing other parameters.
                    Note: ORIGIN X and ORIGIN Y denote the upper left corner of the image.
                    Note: Not used if OSDTEMPLATE is active.
      PERCENT       Blends the rendered OSD image, mixes with the decoded
                    video at the argued percentage. 0 = OSD OFF, while 100
                    gives a solid OSD image.  Accepts offsets (+/-) and absolutes (no sign).
                    The blend will not go below 0% or higher than 100% when + and - parameters
                    are argued.
                    Note: Not used if OSDTEMPLATE is active.
      SCALE WIDTH  (optional) If argued, specifies the width of the OSD image.  Accepts
                    offsets (+/-) and absolutes (no sign) in pixel units.  Also accepts
                    percentage values as absolutes (50%) or as offsets (+50%, -50%).  The
                    offset percent calculation is based on the currently displayed OSD
                    size and the absolute percent calculation is based on the original
                    size of the OSD image.  The width can be 'auto-calculated' to maintain
                    the original OSD's aspect ratio if an 'F' option is argued.  'F' forces
                    the width size based on the SCALE HEIGHT value and the aspect ratio
                    of the original OSD image.  An '*' may be argued to keep the existing
                    value, if changing other parameters.
                    Note: Not used if OSDTEMPLATE is active.
      SCALE HEIGHT  (optional) If argued, specifies the height of the OSD image.  Accepts
                    offsets (+/-) and absolutes (no sign) in pixel units.  Also accepts
                    percentage values as absolutes (50%) or as offsets (+50%, -50%).  The
                    offset percent calculation is based on the currently displayed OSD
                    size and the absolute percent calculation is based on the original
                    size of the OSD image.  The height can be 'auto-calculated' to maintain
                    the original OSD's aspect ratio if an 'F' option is argued.  'F' forces
                    the width size based on the SCALE WIDTH value and the aspect ratio
                    of the original OSD image.  An '*' may be argued to keep the existing
                    value, if changing other parameters.
                    Note: Not used if OSDTEMPLATE is active.

                    SCALE WIDTH and SCALE HEIGHT Considerations:
                   - If SCALE WIDTH is argued then SCALE HEIGHT must also be specified.
                   - If SCALE HEIGHT is argued then SCALE WIDTH must also be specified
                   - If SCALE WIDTH and SCALE HEIGHT are not argued the OSD image will
                     be displayed using the registered size. (DIR S [FILENAME] will show the
                     registered size of the OSD image.)
                   - The 'F' argument can be argued for width or height but not both at the
                     same time.
                   - If the argued width or height is larger than the screen display size,
                     the OSD will be forced to match the screen display size.  An OSD <enter>
                     status command will show the actual displayed size if this occurs.

    CRAWL: Sets parameters and activates the CRAWL if the OSDTEMPLATE is active.  CRAWL is
    not available if OSDTEMPLATE is set to NONE.  The CRAWL will use the default parameters
    set by the current template, or the user may override any of those parameters when the
    OSD CRAWL command is issued.

      ONSCREENDISPLAY|OSD|OD [REGION] CRAWL [X] [Y] [WIDTH] [HEIGHT] [SOURCE]
                                            [SPEED] [DIRECTION] [REPEAT] [FONT] [FONT SCALE]
                                            [FONT COLOR] [BACKGROUND COLOR]
      Argument List:
      Argument      Description
      REGION        Specify which region will run the CRAWL.  This must match the region
                    set up for CRAWL in the active template.
                    This defaults to region 0 (the first region)
      X             Sets X position of the CRAWL. Value must fit the current video
                    display resolution.  Accepts only absolute pixel based values.
                    An '*' may be argued to keep the existing value, if changing other parameters.
                    Note: X and Y denote the upper left corner of the CRAWL box.
      Y             Sets Y position of the CRAWL. Value must fit the current video
                    display resolution.  Accepts only absolute pixel based values.
                    An '*' may be argued to keep the existing value, if changing other parameters.
                    Note: X and Y denote the upper left corner of the CRAWL box.
      WIDTH         Sets width of the CRAWL box. Accepts only absolute pixel based values.
                    Value must fit the current video display resolution, but can be as small as a
                    single pixel.  An '*' may be argued to keep the existing value, if changing
                    other parameters.
      HEIGHT        Sets height of the CRAWL box. Accepts only absolute pixel based values.
                    Height cannot be grater than 300 pixels.  The height must be tall enough
                    to fit the text characters, or the text characters will not be generated.
                    Use the FONT SCALE parameter to change the height of the generated
                    characters.  An '*' may be argued to keep the existing value, if
                    changing other parameters.
      SOURCE        The name of the text file containing the CRAWL text to be displayed.  The
                    path name does not have to be specified. An '*' may be argued to keep the
                    existing value, if changing other parameters.
      SPEED         The speed of the CRAWL, specified by pixels/vertical sync.  If the speed
                    is too fast, the CRAWL may not display clearly.  An '*' may be argued to keep
                    the existing value, if changing other parameters.
      DIRECTION     The direction of the CRAWL.  An '*' may be argued to keep
                    the existing value, if changing other parameters.
                    Terse    Verbose      Description
                        2        R2L      Right to left CRAWL direction
                    Note; Other directions will be supported in future releases.
      REPEAT        The number of times a CRAWL will be repeated.  After the repeat
                    has completed, the OSD CRAWL region will be removed from the display.
                    An '*' may be argued to keep the existing value, if changing other
                    parameters.
                    Terse    Verbose      Description
                        0          0      Infinite repeat
                       'n'        'n'     'n' is the number of times to run the crawl
      FONT NAME     The true type font to be used for the text render.  The system supplies
                    a default font Vera.ttf.  Alternate true type fonts may be uploaded to the hard
                    drive by the user and specified in this parameter.  An '*' may be argued to
                    keep the existing value, if changing other parameters.
      FONT SCALE    Set the size of the rendered text.  At this time, the scale value is an
                    arbitrary number and does not directly correspond to the size of the text
                    for a particular screen resolution.  An '*' may be argued to keep
                    the existing value, if changing other parameters.
      FONT COLOR    Set the color of the rendered text.  The format of the color is ARGB
                    (Alpha, Red, Green, Blue) specified by using hex values.  The alpha value
                    is supported, so that the text can be displayed as an alpha blend.
                    An argument of 'ff00ff00' will result in a solid green character,
                    and an argument of '800000ff' will result in a blue character with
                    a 50% alpha blend.
      BACKGROUND COLOR    Set the background color of the CRAWL text box.  The format of the
                    color is ARGB (Alpha, Red, Green, Blue) specified by using hex values.
                    The alpha value is supported, so that the text can be displayed as an alpha
                    blend.  An argument of 'ff00ff00' will result in a solid green background,
                    and an argument of '800000ff' will result in a blue background with
                    a 50% alpha blend.  An argument of 0 will result in a fully transparent
                    background, so that the CRAWL will display only the rendered characters.

    TEXT: Sets parameters and activates the TEXT region if the OSDTEMPLATE is active.  The TEXT
    is a predefined region that displays specific information using a preset format. The TEXT
    region can update the displayed information periodically.  At this time, the only TEXT types
    available are for time/date display.  TEXT is  not available if OSDTEMPLATE is set to NONE.  The
    TEXT will use the default parameters set by the current template, or the user may override any of
    those parameters when the OSD TEXT command is issued.

      ONSCREENDISPLAY|OSD|OD [REGION] TEXT [X] [Y] [WIDTH] [HEIGHT] [TYPE]
                                            [INTERVAL] [JUSTIFICATION] [REPEAT] [FONT] [FONT SCALE]
                                            [FONT COLOR] [BACKGROUND COLOR]
      Argument List:
      Argument      Description
      REGION        Specify which region will run the TEXT.  This must match the region
                    set up for TEXT in the active template.
                    This defaults to region 0 (the first region)
      X             Sets X position of the TEXT. Value must fit the current video
                    display resolution.  Accepts only absolute pixel based values.
                    An '*' may be argued to keep the existing value, if changing other parameters.
                    Note: X and Y denote the upper left corner of the TEXT box.
      Y             Sets Y position of the TEXT. Value must fit the current video
                    display resolution.  Accepts only absolute pixel based values.
                    An '*' may be argued to keep the existing value, if changing other parameters.
                    Note: X and Y denote the upper left corner of the TEXT box.
      WIDTH         Sets width of the TEXT box. Accepts only absolute pixel based values.
                    Value must fit the current video display resolution, but can be as small as a
                    single pixel.  An '*' may be argued to keep the existing value, if changing
                    other parameters.
      HEIGHT        Sets height of the TEXT box. Accepts only absolute pixel based values.
                    Value must fit the current video display resolution.  The height must
                    be tall enough to fit the text characters, or the text characters will not
                    be generated.  Use the FONT SCALE parameter to change the height of the
                    generated characters.  An '*' may be argued to keep the existing value, if
                    changing other parameters.
      TYPE          The TEXT 'type'.  These are predefined formats specifying the information to be
                    displayed. An '*' may be argued to keep the existing value, if changing other
                    parameters.
                    Terse        Verbose      Description
                        0           NONE      No text format
                        1       TIMEDATE      2 line time and date- HH:MM am/pm  MM/YY/DD
                        2   TIMEDATEINTL      2 line time and date- HH:MM am/pm  YYYY-MM-DD (ISO 8601)
                        3           TIME      1 line time (24 hour clock)- HH:MM:SE
                        4   TIME24DDMMYY      2 line time (24 hour clock) and date- HH:MM DD-MM-YYYY
                    Note; Other TEXT TYPEs will be supported in future releases.
      INTERVAL      The update interval of the TEXT region, in milliseconds.  An '*' may be argued to
                    keep the existing value, if changing other parameters.
      JUSTIFICATION Set the position of the information within the TEXT region.  An '*' may be
                    argued to keep the existing value, if changing other parameters.
                    Terse    Verbose      Description
                        0       NONE      No justification specified
                        1       LEFT      Information will be left justified
                        2     CENTER      Information will be centered
                        3      RIGHT      Information will be right justified
                    Note; At this time, this parameter is ignored, and all information
                          is centered.
      FONT NAME     The true type font to be used for the text render.  The system supplies
                    a default font Vera.ttf.  Alternate true type fonts may be uploaded to the hard
                    drive by the user and specified in this parameter.  An '*' may be argued to
                    keep the existing value, if changing other parameters.
      FONT SCALE    Set the size of the rendered text.  At this time, the scale value is an
                    arbitrary number and does not directly correspond to the size of the text
                    for a particular screen resolution.  An '*' may be argued to keep
                    the existing value, if changing other parameters.
      FONT COLOR    Set the color of the rendered text.  The format of the color is ARGB
                    (Alpha, Red, Green, Blue) specified by using hex values.  The alpha value
                    is supported, so that the text can be displayed as an alpha blend.
                    An argument of 'ff00ff00' will result in a solid green character,
                    and an argument of '800000ff' will result in a blue character with
                    a 50% alpha blend.
      BACKGROUND COLOR    Set the background color of the TEXT box.  The format of the
                    color is ARGB (Alpha, Red, Green, Blue) specified by using hex values.
                    The alpha value is supported, so that the text can be displayed as an alpha
                    blend.  An argument of 'ff00ff00' will result in a solid green background,
                    and an argument of '800000ff' will result in a blue background with
                    a 50% alpha blend.  An argument of 0 will result in a fully transparent
                    background, so that the TEXT will display only the rendered characters.

    OFF: Removes OSD region from the display, but maintains information so that the
         region can be instantly re-displayed with an OSD ON command.  If the OSDTEMPLATE
         is active, OSD OFF will remove CRAWL or TEXT regions from the display.
      ONSCREENDISPLAY|OSD|OD [REGION] OFF
      Argument List:
      Argument      Description
      REGION        (optional) If argued specify which region to change
                               This defaults to region 0 (the first region)

    ON: Activates an OSD region that was previously turned OFF. If the OSDTEMPLATE
        is active, OSD ON will redisplay CRAWL or TEXT regions for the display.
        The OSD ON command is only valid if the region was activated using an OSD D, OSD CRAWL
        or OSD TEXT command and subsequently turned off using the OSD OFF command.
      ONSCREENDISPLAY|OSD|OD [REGION] ON
      Argument List:
      Argument      Description
      REGION        (optional) If argued specify which region to change
                               This defaults to region 0 (the first region)
## Response:
      ONSCREENDISPLAY RESPONSE
        Verbose- "OK\r\n" to acknowledge receipt of command, or
                 "ERROR- [Description]\r\n" if error, ending command
        Terse-   "0\r\n" to acknowledge receipt of command, or
                 "[NON-ZERO NUMERIC VALUE]\r\n" if error, ending command
        "\r\n" concludes modify responses (empty line)
## Examples:
      Verbose command to position and blend an image in region 0.  The position
      will be in the center of the screen.
      *.DCMD OSD D C C 100 <enter>
         Response is: OK\r\n

      Verbose command to position and blend an image in region 3
      *.DCMD OSD 3 D C C 100 <enter>
         Response is: OK\r\n

      Verbose command to position, scale (400x300) and blend an image in region 0
      *.DCMD OSD D C C 100 400 300 <enter>
         Response is: OK\r\n

      Verbose command to change position, maintain scale and blend an image in region 0
      *.DCMD OSD D +24 -27 100 * * <enter>
         Response is: OK\r\n

      Verbose command to maintain position, change scale and blend an image in region 0
      *.DCMD OSD D * * 100 +25% -43% <enter>
         Response is: OK\r\n

      Verbose command to maintain position, change scale width forced aspect ratio and
      blend an image in region 0
      *.DCMD OSD D * * 100 +25% F <enter>
         Response is: OK\r\n

      Verbose command to increase blend by 10%, and maintain position and scale in region 0
      *.DCMD OSD D * * +10 * * <enter>
         Response is: OK\r\n

      Verbose command to display the international time/date text when a template is active
      *.DCMD OSD 3 TEXT * * * * TIMEDATEINTL <enter>
         Response is: OK\r\n

      Verbose command to display the current OSD settings when the template is not active.
       *.DCMD OSD <enter>
       OSD REGION 0
       LOADED image-
         image File: /mnt/hd/media/adtec.bmp
         Size:    341W x 136H
         Created:
       DISPLAYED image
         image File: /mnt/hd/media/adtec.bmp
         Size:    341W x 136H
         Origin:  (0,0)
         Alpha-blend 100 %
       OK

       Verbose command to display the current OSD settings after the
       'OSD D C C 100 -50% F' command was sent and the template is not active.
       *.DCMD OSD <enter>
       OSD REGION 0
       LOADED image-
         image File: /mnt/hd/media/adtec.bmp
         Size:    341W x 136H
         Created:
       DISPLAYED image
         image File: /mnt/hd/media/adtec.bmp
         Size:    170W x 67H
         Origin:  (275,206)
         Alpha-blend 100 %
       OK

      Verbose command to display the current OSD settings after an
      OSD OFF command was sent to the system and the template is not active.
      *.DCMD OSD <enter>
      OSD REGION 0
       LOADED image-
         image File: /mnt/hd/media/adtec.bmp
         Size:    341W x 136H
         Created:
       OSD display is OFF
       OK

      Verbose command to display the current OSD settings when the template is active.
      Note, the regions display 'names' for active templates.
       *.DCMD OSD <enter>

       OSD REGION 0 Template Name: Left Panel
       LOADED IMAGE-
         Image File: OSD Template Image not loaded
         Size:    480W x 810H
         Origin:  (0,0)
       No displayed OSD image

       OSD REGION 1 Template Name: Bottom Panel
       LOADED IMAGE-
         Image File: OSD Template Image not loaded
         Size:    1920W x 270H
         Origin:  (0,810)
       No displayed OSD image

       OSD REGION 2 Template Name: Crawl
       LOADED CRAWL-
         Crawl File: /media/hd0/osd/crawl.txt
         Created: 01/28/2008 15:10
         Size:    1920W x 90H
         Origin:  (0,980)
         Speed: 2  Direction: R2L  Repeat:  0
         Font File: /usr/local/lib/Vera.ttf
         Created: 01/29/2008 13:46
         Scale: 48  Font Color: ff00aa00  Crawl Background Color: ff000080
       Crawl is not active

       OSD REGION 3 Template Name: Date & Time
       LOADED TEXT-
         Text Type: DATETIME
         Size:    480W x 90H
         Origin:  (0,10)
         Refresh: 1000 MilliSeconds  Justification: CENTER
         Font File: /usr/local/lib/Vera.ttf
         Created: 01/29/2008 13:46
         Scale: 36  Font Color: ff00aa00  Crawl Background Color: ff000080
       Text is not active
       OK
## Notes:
      Some of the legacy OSD features are not yet implemented.

      The REGION argument has been added for Gem based products to allow control of multiple OSD
      regions if the OSDTEMPLATE is active.

      The OSD format (BMP, PNG, JPEG, etc) is automatically detected by the system.

      The OSD image does not have to be 'rendered'.  The system is able to display the image
      using the native BMP, JPEG, PNG and GIF formats.

      The size of the image can be specified and changed without having to reload the image.

      The OSD ON command does not exist in the legacy systems.

      PNG images with 'transparency layers' will ignore the PERCENT arguments.  The transparency
      setting will override the alpha blend process in the system.

      Large OSD images with high definition resolution may cause some video tearing if
      a high definition video is playing.  The bit rate of the video is not the issue, rather
      it is the concurrent display of two high resolution images that may cause tearing.
## Products Supporting Command: SoloistHD4111 edjeHD4111 signEdjeHD SoloistHD Pro Created By: Adtec Digital Inc