Page tree

  Wiki Navigation

    Loading...


 Recently Updated


 Latest Releases

 MediaPortal 1.32
            Releasenews | Download
 MediaPortal 2.5
            Releasenews | Download


Table of Contents

Description

This control is used to display images with the MediaPortal skin engine.

Changelog

Change

Date

Version

Image Alignment

2010/10/13

1.1.0 to 1.2.0

Image Masking

2010/11/14

1.1.0 to 1.2.0

Image Caching <shouldCache>

2010/11/24

1.1.0 to 1.2.0

Image Overlay

2012/10/01

1.2.0 to 1.3.0

Image Tile Fill

2010/10/05

1.1.0 to 1.2.0

Image borders

2010/10/10

1.0.1 to 1.1.0

 

 

Tags

Image (GUIImage)

Element Name

Data Type

Description

colorkey

Long

Sets the transparent color

texture[flipX, flipY, diffuse, mask]

String

The filename or #property containing the filename of the texture

   texture[flipx]

Boolean

 

   texture[flipY]

Boolean

 

   texture[diffuse]

String

 

   texture[mask]

String  

Allows to specify a mask that defines the areas of the images that are drawn to screen. See Image Masks for more information on how to use image masks in MediaPortal.

   texture[overlay]

String

Specify an image to blend with the current diffusecolor and then overlay on top of the (main) texture. See TV Guide for an example using image overlays in MediaPortal.

keepaspectratio

Boolean

Set if the aspectratio of the texture needs to be preserved during rendering. Defaults false

zoom

Boolean

Sets if the image should be zoomed in the given rectangle of the control. Defaults false

zoomfromtop

Boolean

Sets if the image should be zoomed into the given rectangle of the control. Zoom with fixed top, center width. Defaults false

fixedheight

Boolean

Sets if the image should retain its height after it has been zoomed or aspectratio adjusted. Defaults false

filtered

Boolean

Unknown. Defaults true

centered

Boolean

(obsolete as of Version 1.2) Sets if the image should be centered in the given rectangle of the control. Defaults false. Use of this tag should be avoided, in future versions it will be removed. Use align and/or valign instead.

align

String

Align the image 'left', 'right' or 'center'. Defaults to 'left'

valign

String

Align the image 'top', 'bottom' or 'middle'. Defaults to 'top'

border[position, textureRepeat, textureRotate, texture, colorKey, corners, cornerRotate]

String

With this feature you have the ability to add borders composed from textures that you identify. Each border is a rectangular shape and each side and corner of the border rectangle is itself a rectangle drawn with the specified border texture. You may border the image at its edge or the control rectangle which contains the image. This feature was introduced with MediaPortal 1.1, see the skin related changes page for the changelog.

   border[position]

BorderPosition

Specifies the position of the border relative to the image or control rectangle edges. Valid values are OutsideImage, InsideImage, CenterImage, OutsideControl, InsideControl, CenterControl. The default value is "OutsideImage". Example: <border position="CenterControl">10</border>

   border[textureRepeat]

Boolean

Specifies whether the texture used for the border should repeat or stretch inside each of the four rectangles that compose the overall border. The default value is "no". Example: <border textureRepeat="yes">10</border>

   border[textureRotate]

Boolean

Specifies whether or not the texture used for the border should be rotated for each of the border rectangles. If the texture should rotate then the texture will be rotated 90 deg for the right border rectangle, 180 deg for the bottom, and 270 deg for the left. The default value is "no". Example: <border textureRotate="yes">10</border>

   border[texture]

String

Specifies the tetxure filename for the border rectangles. A single file is used for all four of the border rectangles. Based on the value of textureRepeat, the entire texture extent is either stretched (scaled up/down) to fill the border rectangles or is scaled (up/down) to fit inside the border rectangle at its native aspect ratio and repeatedly drawn until the border rectangle is filled. The default value is "image_border.png". This texture file must exist in the skin media directory otherwise no border will be drawn. Example: <border texture="my_border.png">10</border>

   border[colorKey]

Long

Specfies the color key for the border texture. The default value is 0xFFFFFFFF. Example: <border colorKey="0x66FFFFFF">10</border>

   border[corners]

Boolean

Specifies that the border should be rendered with corners. When the border should be rendered with corners the image control selects a texture file based on the name of the border,texture attribute. The selected file must end with "_corner" (excluding the extension); e.g., "image_border_corner.png". The default value is "no". Example: <border corners="yes">10</border>

   border[cornerRotate]

Boolean

Specifies whether or not the texture used for the border corner should be rotated for each of the four border corner rectangles. A single texture file is used for all four of the border corner rectangles. If the texture should rotate then the texture will be rotated 90 deg for the upper right border rectangle, 180 deg for the bottom right, and 270 deg for the bottom left. The default value is "no". Example: <border cornerRotate="yes">10</border>

imagepath

String

Image path used to store VUMeter files (Note: What?)

tileFill

Boolean

Will tile a texture to the rectangle rather than stretch it

Inherited by GUIControl

See GUIControl for the full documentation of this control.

Element Name

Data Type

Description

id

Integer

The id of the control. The id will couple the skin file to the code, so if we later on want to check that a user pressed a button, the id will be required and must be unique. For controls that will never be referenced in the code it is safe to set it to "1"

description

String

An optional description of the control for your reference

type

String

The type of the control, for instance "button", "label", "textbox" and all other controls.

posX

Integer

The X-position on the window for this control

posY

Integer

The Y-position on the window for this control

width

Integer

The width of this control

height

Integer

The height of this control

onleft

Integer

The control id to move the focus to when the user moves left. If not specified (or zero) MediaPortal will find the closest control in that direction to move to. As of v1.7.0 Skin Settings and Skin Expressions are also supported. 

onright

Integer

The control id to move the focus to when the user moves right. If not specified (or zero) MediaPortal will find the closest control in that direction to move to. As of v1.7.0 Skin Settings and Skin Expressions are also supported. 

onup

Integer

The control id to move the focus to when the user moves up. If not specified (or zero) MediaPortal will find the closest control in that direction to move to. As of v1.7.0 Skin Settings and Skin Expressions are also supported. 

ondown

Integer

The control id to move the focus to when the user moves down. If not specified (or zero) MediaPortal will find the closest control in that direction to move to. As of v1.7.0 Skin Settings and Skin Expressions are also supported. 

colordiffuse

Long

Allows you to mix a color & a graphics texture. E.g. If you have a graphics texture like a blue button you can mix it with a yellow color diffuse and the end result will be green. Defaults to 0xFFFFFFFF

dimColor

Integer

Color for a control when it is not focussed. Defaults to half transparent (0x60ffffff)

onfocus

String

[Since 1.3] Executes a MediaPortal skin function when the control gains focus.  See Skin Settings for more information.

XML examples

<control>
  <description>Satellite image</description>
  <type>image</type>
  <id>1000</id>
  <posX>240</posX>
  <posY>200</posY>
  <width>440</width>
  <height>350</height>
  <texture mask="video_poster_mask.png"></texture>
  <visible>no</visible>
  <colorkey>00000000</colorkey>
  <colordiffuse>White</colordiffuse>
  <filtered>yes</filtered>
  <align>center</align>
  <valign>middle</valign>
  <keepaspectratio>yes</keepaspectratio>
</control>

   

 

This page has no comments.