Add Video Support to an Existing Theme?
-
How do I add video support to an existing theme? Is there a simple guide on this?
-
I'm new here, but I want to start contributing so I'll give this a shot...
From what I understand, the main theme xml file needs to have a section for md_video... something like this:
<view name="video"> <video name="md_video"> <pos>0.763 0.400</pos> <origin>0.5 0.5</origin> <size>0.366 0.480</size> <delay>0.2</delay> <default></default> <showSnapshotNoVideo>true</showSnapshotNoVideo> <showSnapshotDelay>false</showSnapshotDelay> </video> </view>
Then inside each system's specific theme.xml file you would add the reference to the video view name:
<view name="video"> ... </view>
Then in the gamelist.xml for the system you can add a video tag to the xml:
<video>~/.emulationstation/video/nes/1942.mp4</video>
That seems to be the basic setup.
To be honest, the easiest way would be to look at a theme that already has video support like... carbon - and then just check the xml files to see how it is configured and copy/paste it into your existing theme. With a little trial and error, you could probably get it going very quickly.
-
@RWM79 That's exactly how to do it, just look at how it is implemented in Carbon and copy it across ensuring the paths are changed to point at the correct places in your theme.
No need to re-invent the wheel. I did this to implement a modified carousel on my own custom theme. -
A problem I am having is the video is BEHIND the screenshot...
I tried adding the following, but its not making a difference:
<feature supported="z-index"> <view name="video"> <image name="md_image"> <zIndex>3</zIndex> </image> <video name="md_video"> <zIndex>2</zIndex> </video> </view> </feature>
-
@Jaxel I'm not sure if you have done this yet, but I know that the z-index stuff was just recently added so if you haven't updated your setup script and then updated emulationstation you might not have a version that supports z-index. The latest z-index fix went in on May 24th.
-
@RWM79 oh... I am using the ES Toolkit.
-
-
@jdrassa I'm on lunch break in a couple of hours, so I can do it then, or it will have to wait until tonight or tomorrow.
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.