Sign up here and you can log into the forum!

Beginers Guide to creating custom OSD

Anything and everything related to OSD modifcation & theming.

Beginers Guide to creating custom OSD   

Postby KAD » Thu Sep 30, 2010 6:37 pm

Here's the steps to creating an up to date stock.osd.bin prior to starting a new mod
(steps are a compilation of tips from mad_ady and recliq posted in this thread)
- note this requires devtools.app.bin - if you don't have it yet, use WEC to download it

Log in to your WDLXTV via telnet/ssh
insert thumbdrive
Create an editable file for your osd.bin
Code: Select all
dd if=/dev/zero of=/tmp/mnt/USB-UID/stock.osd.bin bs=1024k count=30

/tmp/mnt/USB-UID/ must be adjusted to match your thumbdrive
count=30 will create a 30MB file, you can adjust the count as desired
format the file created to ext3
Code: Select all
mke2fs -m 0 -t ext3 /tmp/mnt/USB-UID/stock.osd.bin

make temporary directory
Code: Select all
mkdir /tmp/newosd

mount your osd.bin to the temporary directory
Code: Select all
mount -o loop,rw /tmp/mnt/USB-UID/stock.osd.bin /tmp/newosd

svn check the current revision of stock osd
for firmware 1.02.21: (WDTV Live only)
Code: Select all
svn export https://svn.wdlxtv.com/svn/wdlxtv-live/trunk/osd /tmp/newosd --force

for firmware 1.05.04: (I recommend using the plus trunk for any new mod based on firmware 1.05.04, by doing this your mod will be compatible with both the Live and Live Plus)
Code: Select all
svn export https://svn.wdlxtv.com/svn/1.05.04-wdlxtv/plus/trunk/osd /tmp/newosd --force

Code: Select all
sync

unmount your new osd
Code: Select all
umount /tmp/newosd

reboot to enable your new osd
Code: Select all
reboot


Fast FTP Method to osd modding

What do you need
FTP client like filezilla
telnet/ssh client like putty
text editor that understands xml like notepad++

boot your WD with your new stock.osd.bin
edit the xml's and images in your favorite editing programs

copy your edited files to your stock.osd.bin that is running on your WD
this will replace the stock xml or image with your edited version

to see your changes you must leave the screen
when you return to the screen you will see your edits

to save your work reboot

TIP: use putty to find out what xml to edit
Code: Select all
tail -f /tmp/dmaosd.log

when you exit a screen you will see an entry
******.xml popped
example - villa_home.xml is popped

now you know what xml to edit

Original Method
Intro to OSD MODDING

If I can do this so can you!!!!!!! :mrgreen:

First let's set up you're computer for OSD modding

You'll need programs for the following:
graphics editing
XML editing
Linux OS

Here's how I started.

since I don't have a computer specific for linux I installed
VMWare Player on my vista laptop
VMWare Player is free and allows you to set up a linux OS without needing another computer
http://www.vmware.com/products/player/

Once VMWare player was installed, I downloaded and installed Kubuntu
Kubuntu is a free linux distribution, which I installed inside VMWare Player as the Operating system

Next download the stock.osd.bin , this will be your framework for creating your own theme
by using this you will not need to learn to create your own .bin file
http://forum.wdlxtv.com/viewtopic.php?f=45&t=132&start=10#p805

an additional program that you may find helpful is:
explore2fs - this will allow you access to the files inside stock.osd.bin within a windows environment, you'll simply export the directory to whatever folder you desire within windows, you can then edit any photo's or xml's with your favorite windows based editing programs
http://www.chrysocome.net/explore2fs

if you like you can configure vmware player to share files between your 2 desktops, but for ease, I simply used a usb stick, copied stock.osd.bin and renamed it kad.osd.bin you can name your mod whatever you like xxxx.osd.bin

I then copied the file to the kubuntu desktop
and created a folder on the desktop called "osd"
this folder will be the mounting point for accessing files within xxxx.osd.bin

in kubuntu open the terminal from the location of stock.osd.bin

type
Code: Select all
sudo mount -o loop stock.osd.bin osd

where

stock.osd.bin = the name of your osd.bin file
osd = the name of the folder your created earlier on desktop (mounting point)

if you have chosen different locations for your stock.osd.bin or your folder used for a mounting point you will need to adjust the commands for the correct path and directory

the above command will prompt for sudo password, sudo is the equivelent of administrator
and should be the password for your user id in kubuntu, if you're the administrator, which I suspect you are, type your password and key "enter"

now check the osd folder
you should see several folders and alot of xml's

trouble shooting
if you do not see the files, but file manager shows any number of files
if you can see xml's but upon entering the folder images you can't see anything
if you can not paste your edited images into the images folder

go to the terminal and type
Code: Select all
sudo chmod -R 777 osd

where

osd = the folder created earlier (mounting point)

this will adjust the file permissions so that everything is editablenow just copy paste your edited jpg. .png or .xml files, which you edited with your favorite editing program

there are a couple of images from the images folder that are used, example

villa_bg.jpg
screen_saver.png

the majority of icons used are located at images/villa/

some examples include:
video icon selected = home_video_main_icon_f.png
video icon not selected = home_video_main_icon_n.png
photo icon selected = home_photo_main_icon_f.png
photo icon not selected = home_photo_main_icon_n.png
music icon selected = home_music_main_icon_f.png
music icon not selected = home_music_main_icon_n.png
setting icon selected = home_setting_main_icon_f.png
setting icon not selected = home_setting_main_icon_n.png

and of coarse many more

once all your files are in place
go to your terminal and type
Code: Select all
sudo umount osd

where

osd = folder created earlier (mounting point)

this will unmount the osd.bin file and save all the changes you have made

now copy your modified xxxx.osd.bin it to your usb stick and insert into wdtvlive and reboot

you should see the effect of your changes

of coarse many other things can be changed

the xml files describe image location and attributes
the majority of the home page is taken from villa_home.xml
I'm still learning how to edit xml's but I found the linux program "Kate"
which is included in kubuntu does just fine

you'll find most items are described with:
x=(horizotal starting point) 0 is left
y=(vertical starting point) 0 is top
w=(width of image)
h=(hight of image)
textcolor="0xC0C0C0"
etc

I plan to update this guide as possible and invite more experience OSD modders to fill in gaps. and outline more complex items not addressed here which might include more detail on xml editing, text editing, custom scripts, svn updatable, etc

2 additional resources/tools are:
http://b-rad.cc/877/wdtv-osd-how-to-make-a-custom-theme/
http://wdtvforum.com/main/index.php?PHPSESSID=3c5frc3dv7rc2s0ao8ups9hj00&topic=1626.0

KAD
If you like my work please consider a Donation. Donate
Please read the appropriate documentation before posting questions! READ ME FAQ WIKI
PM's are for private matters. Post support questions to the appropriate forum, or they will be ignored.
User avatar
KAD
Global Moderator
 
Posts: 5103
Joined: Mon Apr 12, 2010 4:59 pm
Location: Seattle, WA USA

Re: Beginers Guide to creating custom OSD   

Postby kismiace » Thu Sep 30, 2010 7:05 pm

thx for this greatly appreciated
kismiace
n00b
 
Posts: 19
Joined: Thu Aug 19, 2010 9:08 pm

Re: Beginers Guide to creating custom OSD   

Postby PsychoTHC » Fri Oct 01, 2010 4:25 am

good job KAD :!:

I want to add my way of OSD moding, maybe also useful for others.

Problem:
How to find out what xml files are related to any screen.
Solution:
1. Try to find any unique graphic image on screen.
2. Find out the name of the graphic in "osd/image/" or "osd/image/villa"
3. Go WinRar upper menu "search files" and let display all xmls files containing this image name.

Problem:
Find out new coordinates for positioning of text or images inside xml files
Solution:
1. You need to make screenshot of the screen you want to modify.
2. Use "WDTV Live - Remote Controller" http://sourceforge.net/projects/wdtvtelnetremot/
3. Once you have your WDTV screen at your PC visible, enlarge the window as big as possible.
4. Make a sceen dump by pressing "Alt - Print" on your keyboard.
5. Open a.e. Photoshop and import clipboard as new image.
6. Cut out the real screen dump out of the rest. Do this very accurat!!!
7. Resize image to 1280x725 pixels (EDIT: 1280 x 720)
8. Enable "Show coordinates" at Photoshop upper menu. So coordinates will shown when you move mouse inside image.
With this you are able to move, add, modify text or graphics without testing thousend of times correcting the coordinates. So you change coordinates and they fit from the first time.

Hope this helped for some people to make it easier to mod.
cheers mike
Last edited by PsychoTHC on Fri Oct 01, 2010 9:23 am, edited 1 time in total.
User avatar
PsychoTHC
OSD Themer
 
Posts: 117
Joined: Tue Apr 13, 2010 9:33 pm
Location: Germany, Karlsruhe

Re: Beginers Guide to creating custom OSD   

Postby recliq » Fri Oct 01, 2010 7:45 am

7. Resize image to 1280x725 pixels

:?:
Why do you scale to 1280x725 pixel??
IMHO the screen of the WDTV is 1280x720...
­WDLXTV Project Maintainer
-:] If you like my contributions feel free to donate for a beer or a new flash drive. ...and always remember: RTFM! (README, FAQ, WIKI) [:-
User avatar
recliq
WDLXTV Team
 
Posts: 5513
Joined: Thu Apr 15, 2010 8:09 am
Location: Kiel, Germany

Re: Beginers Guide to creating custom OSD   

Postby KAD » Fri Oct 01, 2010 7:54 am

I'll second recliq's question about x 725, in my tinkering I've used 1280 x 720 backgrounds with no problems but also noticed the stock.osd.bin has a background of 1280 x 800 :?:

KAD
If you like my work please consider a Donation. Donate
Please read the appropriate documentation before posting questions! READ ME FAQ WIKI
PM's are for private matters. Post support questions to the appropriate forum, or they will be ignored.
User avatar
KAD
Global Moderator
 
Posts: 5103
Joined: Mon Apr 12, 2010 4:59 pm
Location: Seattle, WA USA

Re: Beginers Guide to creating custom OSD   

Postby PsychoTHC » Fri Oct 01, 2010 12:53 pm

Yes its 720, i don't know why I wrote 725. :roll:

I want to show you a photoshop picture where you can see how a previous video-info page was born in my mod. Just playing arount until i liked the positions.
Image
You can also see the background of some images are filled with pink color. That makes it easier to find out the x,y coordinates of the left/upper corner of transparent symbols. ;)
User avatar
PsychoTHC
OSD Themer
 
Posts: 117
Joined: Tue Apr 13, 2010 9:33 pm
Location: Germany, Karlsruhe

Re: Beginers Guide to creating custom OSD   

Postby kismiace » Fri Oct 01, 2010 1:08 pm

hi guys i have a question or more like a problem when i unmount my custom.osd.bin and put it on my stick i cant then remove it because it is read only what am i doing wrong?
kismiace
n00b
 
Posts: 19
Joined: Thu Aug 19, 2010 9:08 pm

Re: Beginers Guide to creating custom OSD   

Postby KAD » Fri Oct 01, 2010 3:02 pm

@kismiace,

I've never had that type of permissions problem, but did you try
Code: Select all
sudo chmod -R 777 <folder name>
example
sudo chmod -R 777 osd


or I suppose to run it on the file, if it's already unmounted

Code: Select all
sudo chmod -R 777 xxx.osd.bin

I've had to use this many other times to fix some permissions issues on the mounted folder

as for getting the xxxx.osd.bin to usb, I've always just copied it onto the usb, so that I still had the file to work with in kubuntu

KAD
If you like my work please consider a Donation. Donate
Please read the appropriate documentation before posting questions! READ ME FAQ WIKI
PM's are for private matters. Post support questions to the appropriate forum, or they will be ignored.
User avatar
KAD
Global Moderator
 
Posts: 5103
Joined: Mon Apr 12, 2010 4:59 pm
Location: Seattle, WA USA

Re: Beginers Guide to creating custom OSD   

Postby kismiace » Fri Oct 01, 2010 3:24 pm

KAD wrote:@kismiace,

I've never had that type of permissions problem, but did you try
Code: Select all
sudo chmod -R 777 <folder name>
example
sudo chmod -R 777 osd


or I suppose to run it on the file, if it's already unmounted

Code: Select all
sudo chmod -R 777 xxx.osd.bin

I've had to use this many other times to fix some permissions issues on the mounted folder

as for getting the xxxx.osd.bin to usb, I've always just copied it onto the usb, so that I still had the file to work with in kubuntu

KAD



ya i had to do sudo chmod -R 777 osd
to see all of the files and when i was done messin with stuff
i typed sudo umount osd
osd is my folder name i then dragged my osd.bin to my windows desktop and after i put it on my mem stick i couldnt take it off or delete it so i had to run a cmd prompt and chkdsk /f to get rid of it.
im not sure what happened but ill try again and see what happens
maybe moving it from Kubuntu to windows messed it up idk
kismiace
n00b
 
Posts: 19
Joined: Thu Aug 19, 2010 9:08 pm

Re: Beginers Guide to creating custom OSD   

Postby KAD » Fri Oct 01, 2010 3:33 pm

I bet you're right, anytime I've tried to share/access files between windows/kubuntu or vis vera, something always gets messed up, I also never attempted to drag drop, etc from kubuntu to windows, I always directed into to kubuntu, then plugged in my usb, this way the usb shows up as a kubuntu attached device and not a windows attached device, after copying to usb, I right clicked on drive in kubuntu to disconnect device, which automatically connects it to the win host, disconnecting from the windows host does not connect the device to kubuntu, so once, it's safe to remove from windows, just pull the usb

KAD
If you like my work please consider a Donation. Donate
Please read the appropriate documentation before posting questions! READ ME FAQ WIKI
PM's are for private matters. Post support questions to the appropriate forum, or they will be ignored.
User avatar
KAD
Global Moderator
 
Posts: 5103
Joined: Mon Apr 12, 2010 4:59 pm
Location: Seattle, WA USA

Next

Return to WDTV G2 & WDTV Live Theming

Who is online

Users browsing this forum: No registered users and 1 guest