View Full Version : Guitar Fret Board
ocwasere
2007-04-15, 00:37
I'm trying to code a fret board and i'm stuck
I need to order key[1] with key[0]
EFGABCD
BCDEFGA
GABCDEF
DEFGABC
ABCDEFG
EFGABCD
any help please
key = ('EBGDAE','EFGABCD','1221222')
for i in range(len(key[0])): # = 'EBGDAE'
for s in key[1]: # = 'EFGABCD' I need to change the order here
print s,
if s != 'B':
if s != 'E':
print '#',
print
debug output
E F # G # A # B C # D #
E F # G # A # B C # D #
E F # G # A # B C # D #
E F # G # A # B C # D #
E F # G # A # B C # D #
E F # G # A # B C # D #
>>>
i need this
E F # G # A # B C # D #
B C # D # E F # G # A #
G # A # B C # D # E F #
D # E F # G # A # B C #
A # B C # D # E F # G #
E F # G # A # B C # D #
don't need
C # D # E F # G # A # B
F # G # A # B C # D # E
Thanks
ocwasere
2007-04-15, 00:54
I'm trying to code a fret board and i'm stuck
I need to order key[1] with key[0][i]
EFGABCD
BCDEFGA
GABCDEF
DEFGABC
ABCDEFG
EFGABCD
any help please
key = ('EBGDAE','EFGABCD','1221222')
for i in range(len(key[0])): # = 'EBGDAE'
for s in key[1]: # = 'EFGABCD' I need to change the order here
print s,
if s != 'B':
if s != 'E':
print '#',
print
debug output
E F # G # A # B C # D #
E F # G # A # B C # D #
E F # G # A # B C # D #
E F # G # A # B C # D #
E F # G # A # B C # D #
E F # G # A # B C # D #
>>>
i need this
E F # G # A # B C # D #
B C # D # E F # G # A #
G # A # B C # D # E F #
D # E F # G # A # B C #
A # B C # D # E F # G #
E F # G # A # B C # D #
don't need
C # D # E F # G # A # B
F # G # A # B C # D # E
Thanks
ocwasere
2007-04-15, 02:55
key = ('EBGDAE','EFGABCD','1221222')
for i in range(len(key[0])):
for s in range(len(key[1])):
if key[0][i] == key[1][s]:
print 'key[0][i] = ',key[0][i],' key[1][s] = ',key[1][s]
debug output
key[0][i] = E key[1][s] = E
key[0][i] = B key[1][s] = B
key[0][i] = G key[1][s] = G
key[0][i] = D key[1][s] = D
key[0][i] = A key[1][s] = A
key[0][i] = E key[1][s] = E
>>>
ocwasere
2007-04-15, 10:23
for i in range(len(key[0])):
for s in range(len(key[1])):
if key[0][i] == key[1][s]:
for s in key[1][s:]+key[1][:s]: # All the E scale EFGABCD
print s,
if s != 'B':
if s != 'E':
print '#',
print
>>>
E F # G # A # B C # D #
B C # D # E F # G # A #
G # A # B C # D # E F #
D # E F # G # A # B C #
A # B C # D # E F # G #
E F # G # A # B C # D #
>>>
ocwasere
2007-04-15, 16:04
can someone take a look at these pictures Please and tell me whats happening
25 ControlImage(x,y,1,60, RootDir + 'fill.png')" 'fill.png'=1x1 white pixel
screenshot in xbmc_pc note fret 8 13 20 (http://www.ocsweb.co.uk//guitar/xbmc/screenshot/xbmc_pc.jpg) width should be 1 "ControlImage(x,y,1,60, RootDir + 'fill.png')" 'fill.png'=1x1 white pixel
screenshot in xbmc (http://www.ocsweb.co.uk//guitar/xbmc/screenshot/xbmc.jpg) here the width looks right but it fades to the bottom
picture from my phone of the tv (http://www.ocsweb.co.uk//guitar/xbmc/screenshot/zoom.jpg) picture is poor quality but it shows what is wronge plus the lines look way to thick
thanks
ocwasere
2007-04-16, 17:04
# ControlImage(x, y, width, height, filename[, colorKey, aspectRatio])
can some one tell me why aspectRatio default stretch fill.png produces colour bleeding
when aspectRatio default stretch fill.gif doesn't
is it do with colorKey 0x??FFFFFF if so how do i stop a 1x1 white pixel from bleeding the colour
i whan to use png's but i need strait lines
# fill.png = 181 bytes (1x1 white pixel) look here fill png (http://www.ocsweb.co.uk/guitar/xbmc/screenshot/xbmc.jpg)
ControlImage(x,y,1,60, RootDir + 'fill.png'))
# fill.gif = 807 bytes (1x1 white pixel) look here fill gif (http://www.ocsweb.co.uk/guitar/xbmc/screenshot/xbmcgif.jpg)
ControlImage(x,y,1,60, RootDir + 'fill.gif'))
thanks
Nuka1195
2007-04-16, 18:41
it depends on how you create the png.
In photoshop, I notice if I change the opacity for the level it screws up, but if i create the level with fill at the opacity I want it works fine.
I'm no photoshop expert, so I hope that helps.
ocwasere
2007-04-16, 20:22
thanks Nuka1195 for you reply
it works well with a 1 pixel gif but not with a 1 pixel png
png seems to render half white half transparent even if the png is set to no transparency
if i use a png with 2 white pixels it works
thanks