Babyklappe-Eingang



Babyklappe-Eingang

David Strutz, 23.05.2006 22:10: 


Baby-Klappe

Beitrag, 06.08.2006 23:48: ;createCode()'Source wurde am 06.08.2006 in die Babyklappe auf XProfan.Com abgelegt:declare s$windowtitle "ShutDown"s$:=input$("ShutDownZeit:","ShutDownZeit:",time$(0))case (s$=="") : endclssettimer 50000while 1   locate 1,1   print time$(0)," -> ",s$   waitinput   if %wmtimer      case (time$(0)==s$) : exitwindows 0   endifwendend


Baby-Klappe

Beitrag, 09.08.2006 14:50: [code:1:071b3ffffe]'Source wurde am 09.08.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc dlg_input
parameters _hwnd&,prompt$,title$,cancle$,typ$,lenlimit&,pre$
declare dlg%,ip&,tx%,ex%,ss$,ok%,ca%,myfont&,myfontc&

enablewindow _hwnd&,0
myfont&:=createfont("MS Sans Serif",10,0,0,0,0)
myfontc&:=createfont("Courier New",16,0,1,0,0)
windowstyle 512

dlg%:=createdialog(_hwnd&,title$,%maxx\2-150,%maxy\2-120,300,128)
tx%:=creategroupbox (dlg%,prompt$,10,13,270,30)
ok%:=createbutton(dlg%,"&OK",sub(width(dlg%),88),sub(height(dlg%),34),75,23)
ca%:=createbutton(dlg%,cancle$,sub(width(dlg%),90*2)+9,sub(height(dlg%),34),75,23)

setfont ok%,myfont&
setfont ca%,myfont&

showwindow (tx%,0)
setfont tx%,myfont&
showwindow (tx%,1)
if equ$("date",typ$)
ip&:=Create("DateEdit",dlg%,pre$,10,30,270,20)
setfont ip&,myfont&
elseif equ$("time",typ$)
ip&:=Create("TimeEdit",dlg%,pre$,10,30,270,20)
setfont ip&,myfont&
elseif equ$("spin",typ$)
ip&:=Create("SpinEdit",dlg%,pre$,10,30,270,20)
setfont ip&,myfont&
elseif equ$("password",typ$)
ip&:=createedit (dlg%,pre$,10,30,270,-20)
setfont ip&,myfontc&
else
ip&:=createedit (dlg%,pre$,10,30,270,20)
setfont ip&,myfont&
endif

case (lenlimit&) : sendmessage (ip&,197,lenlimit&,0)

sendmessage(ip&,$00B1,0,255)

showwindow (ip&,0)
showwindow (ip&,1)

setfocus(ip&)
whilenot ex%
waitinput

ifnot %wmtimer
case or(equ(%key,13),clicked(ok%)) : ex%=1
if or(equ(%key,2),clicked(ca%))
ex%=2
settext ip&,""
endif

endif
wend

sleep 100
enablewindow dlg%,0
enablewindow ca%,0
enablewindow ok%,0
sleep 300
ss$=gettext$(ip&)
destroywindow (ca%)
destroywindow (ok%)
destroywindow (ip&)
destroywindow (tx%)
destroywindow (dlg%)
enablewindow _hwnd&,1
setactivewindow (_hwnd&)
deleteobject myfont&
deleteobject myfontC&

return if(ex%=1,ss$,"")

endproc[/code:1:071b3ffffe]


Baby-Klappe

Beitrag, 09.08.2006 15:20: [code:1:086f48f8d4]'Source wurde am 09.08.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc sortinternlist
'ein Befehl der IMHO dem XProfan einfach fehlt.
'salve

declare h&,i&

h&:=Control("LISTBOX","", $102,0,0,0,0,0,0,0)

movelisttolist(h&)

i&:=%getcount

clearlist

whileloop 0,i&

addstring getstring$(h&,&loop)

wend

destroywindow(h&)

endproc
proc rsortinternlist
'ein Befehl der IMHO dem XProfan einfach fehlt.
'salve

declare h&,i&

h&:=Control("LISTBOX","", $102,0,0,0,0,0,0,0)

movelisttolist(h&)

i&:=%getcount

clearlist

whileloop i&,0,-1

addstring getstring$(h&,&loop)

wend

destroywindow(h&)

endproc
addfiles "*.inc"
rsortinternlist
sortinternlist
listbox$("",1)
[/code:1:086f48f8d4]


Baby-Klappe

Beitrag, 09.08.2006 17:17: [code:1:8e1d205759]'Source wurde am 09.08.2006 in die Babyklappe auf XProfan.Com abgelegt:
Proc File_get_contents
Parameters Fle$
Declare B&,M#
B&=Filesize(Fle$)
Case B&<0 : Return ""
Dim M#,B&
B&=Blockread (Fle$, M#, 0,B&)
Fle$=Char$(M#,0,B&)
Dispose M#
Return Fle$
Endproc
Proc File_put_contents
Parameters Fle$,S$
Declare L&,M#
L&=Len(S$)
Dim M#,L&+1
String M#,0=S$
Blockwrite Fle$, M#, 0, L&
Dispose M#
Endproc[/code:1:8e1d205759]


Baby-Klappe

Beitrag, 09.08.2006 17:27: [code:1:a0be4587a4]'Source wurde am 09.08.2006 in die Babyklappe auf XProfan.Com abgelegt:
'wod: Kommentare liebe Poster, Kommentare !!! (Ich versuchs mal)
' Diese Prozedur trennt die Worte in s$ an der Stelle c$ (z.B. ein Komma) auf
' und speichert die einzelnen Worte in der ListBox-Liste.
proc explode
parameters c$,s$
clearlist
declare cc&,i&
if (instr(c$,s$)) or (len(s$))
cc&:=len(s$)-len(translate$(s$,c$,""))+1
for i&:=1 to cc& do begin
addstring substr$(s$,i&,c$)
end
endif
endproc[/code:1:a0be4587a4]


Baby-Klappe

Beitrag, 09.08.2006 17:28: [code:1:699159a821]'Source wurde am 09.08.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc minimize
declare caps&

showwindow(%hwnd,2)

setactivewindow(%desktop)

waitinput
endproc[/code:1:699159a821]


Baby-Klappe

Beitrag, 09.08.2006 17:29: [code:1:f5ec5d3e94]'Source wurde am 09.08.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc makeFilenameFine
parameters s$

declare i&,c&,ss$,oks$,ch$

c&:=len(s$)

casenot c& : return ""

oks$="abcdefghijklmnopqrstuvwxyz.ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 /-:\\"

ss$:=""

for i&:=1 to c& do begin

ch$:=mid$(s$,i&,1)

case instr(ch$,oks$) : ss$:=ss$+ch$
end

ss$:=trim$(translate$(ss$," ","-"))
ss$:=trim$(translate$(ss$,"--","-"))
ss$:=trim$(translate$(ss$,"-"," "))

return ss$

endproc[/code:1:f5ec5d3e94]


Baby-Klappe

Beitrag, 09.08.2006 17:30: [code:1:59868efc1e]'Source wurde am 09.08.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc ip2ip
parameters l1&,l2&,l3&,l4&

return (l1&*16777216)+(l2&*65536)+(l3&*256)+l4&
endproc[/code:1:59868efc1e]


Baby-Klappe

Beitrag, 10.08.2006 11:25: [code:1:d73024cd8f]'Source wurde am 10.08.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc lb_getselstring
'verhindert eine fehlermeldung wenn cursel -1 ist.

parameters lb&

declare p&

p&:=getcursel(lb&)

case (p&==-1) : return ""

return getstring$(lb&,p&)

endproc [/code:1:d73024cd8f]


Baby-Klappe

Beitrag, 10.08.2006 11:36: [code:1:bd15c61abc]'Source wurde am 10.08.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc lb_getselstring
'verhindert eine fehlermeldung wenn cursel -1 ist.
'andere variante

parameters lb&

declare p&,s$

p&:=getcursel(lb&)

if (p&==-1)

if getcount(lb&)

lb_setpos lb&,0

s$:=getstring$(lb&,0)

else

s$:=""

endif

else

s$:=getstring$(lb&,p&)

endif

return s$

endproc
Proc LB_SETPOS

Parameters Handl%,Num%
if lt(num%,getcount(Handl%))

Selectstring(Handl%,Num%,Getstring$(Handl%,Num%))

else

sub num%,1
Selectstring(Handl%,Num%,Getstring$(Handl%,Num%))

endif
EndProc[/code:1:bd15c61abc]


Baby-Klappe

Beitrag, 02.09.2006 01:10: [code:1:7a74670ae8]'Source wurde am 02.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
http://xprofan.com/beitrag.php?7547[/code:1:7a74670ae8]


Baby-Klappe

Beitrag, 07.09.2006 18:17: [code:1:ca61000626]'Source wurde am 07.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
{$cleq}
decimals 0
cls
print converteHexToDecInString("MCHT_TITLE | MCHT_PREV | $3 and (MCHT_TITLE | MCHT_PREV | $FF*$700)")
waitkey
end
proc converteHexToDecInString
parameters s$

declare l&

s$:=s$+" "

l&:=len(s$)

declare i&,modi%,c$,ad$,n&,nw$,co&

modi%:=0
ad$:=""
nw$:=""

for i&:=1 to l& do begin

c$:=mid$(s$,i&,1)
co&:=ord(c$)

if co&==36

modi%:=1

/*
elseif ((c$=="0") | \
(c$=="1") | \
(c$=="2") | \
(c$=="3") | \
(c$=="4") | \
(c$=="5") | \
(c$=="6") | \
(c$=="7") | \
(c$=="8") | \
(c$=="9") | \
(c$=="A") | \
(c$=="B") | \
(c$=="C") | \
(c$=="D") | \
(c$=="E") | \
(c$=="F"))
*/

elseif ((co&>47) & (co&<58)) or ((co&>64) & (co&<71))

if modi%==1

ad$:=ad$+c$


else

nw$:=nw$+c$

endif

else

modi%:=0

if len(ad$)

nw$:=nw$+str$(val("$"+ad$))+c$
ad$:=""

else

nw$:=nw$+c$

endif



endif


end

return mid$(nw$,1,len(nw$)-1)

endproc[/code:1:ca61000626]


Baby-Klappe

Beitrag, 07.09.2006 18:22: [code:1:06501e2027]'Source wurde am 07.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc converteHexToDec
//gibt beides (hex und dec) im string zurück / anderer Mechanismus
parameters s$

declare l&

s$:=s$+" "

l&:=len(s$)

declare i&,modi%,c$,ad$,n&,nw$,co&

modi%:=0
ad$:=""
nw$:=""

for i&:=1 to l& do begin

c$:=mid$(s$,i&,1)
co&:=ord(c$)

if co&==36

modi%:=1

/*
elseif ((c$=="0") | \
(c$=="1") | \
(c$=="2") | \
(c$=="3") | \
(c$=="4") | \
(c$=="5") | \
(c$=="6") | \
(c$=="7") | \
(c$=="8") | \
(c$=="9") | \
(c$=="A") | \
(c$=="B") | \
(c$=="C") | \
(c$=="D") | \
(c$=="E") | \
(c$=="F"))
*/

elseif ((co&>47) & (co&<58)) or ((co&>64) & (co&<71))

if modi%==1

ad$:=ad$+c$


else

nw$:=nw$+c$

endif

else

modi%:=0

if len(ad$)

nw$:=nw$+"[$"+ad$+"|"+str$(val("$"+ad$))+"]"+c$
ad$:=""

else

nw$:=nw$+c$

endif



endif


end

return nw$

endproc[/code:1:06501e2027]


Baby-Klappe

Beitrag, 08.09.2006 18:48: [code:1:f3a5cd2831]'Source wurde am 08.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc catchLineFromMultiEditByCharPos
parameters h&,p&

declare s$,sp&,l&

sp&:=p&

s$:=gettext$(output&)
l&:=len(s$)

while (p&>0)

case (mid$(s$,p&,1)==chr$(10)) : break

p&-

wend

swap p&,sp&

while (p&<l&)
case (mid$(s$,p&,1)==chr$(10)) : break
p&+
wend
return trim$(mid$(s$,sp&,p&-sp&))

endproc[/code:1:f3a5cd2831]


Baby-Klappe

Beitrag, 08.09.2006 19:18: [code:1:e07f31ccfb]'Source wurde am 08.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc SelectLineFromMultiEditByCharPos
parameters h&,p&

declare s$,sp&,l&

sp&:=p&

s$:=gettext$(output&)
l&:=len(s$)

while (p&>0)

case (mid$(s$,p&,1)==chr$(10)) : break

p&-

wend

swap p&,sp&

while (p&<l&)
case (mid$(s$,p&,1)==chr$(10)) : break
p&+
wend
sendmessage(output&,177,sp&,p&-1)

endproc[/code:1:e07f31ccfb]


Baby-Klappe

Beitrag, 08.09.2006 22:55: [code:1:96607d56e4]'Source wurde am 08.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
Proc isnum
Parameters S$
Declare I&,C&,Oks$,ok&

s$:=trim$(s$)

case mid$(s$,1,1)=="$" : s$:=del$(s$,1,1)

C&:=Len(S$)

Casenot C& : Return 0

Oks$="0123456789"
ok&:=1

For I&:=1 To C& Do Begin
ifnot Instr(Mid$(S$,I&,1),Oks$)
ok&-
break
Endif
end
Return ok&
Endproc[/code:1:96607d56e4]


Baby-Klappe

Beitrag, 25.09.2006 00:07: [code:1:cd76674b36]'Source wurde am 25.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
DEF @LoadImage(6) !"USER32","LoadImageA"
Declare ICONHANDLE&,ICONHOLDER$,Mod_Name#,Brush&,Refresh_Static&,Refresh&
Windowtitle "Iconbutton mit Text"
Windowstyle 31+512
WINDOW 0,0-640,440
'Buttons und Statics erstellen
'LET Refresh&=@Createbutton(%HWND,"<<< aktualisieren",360,240,150,30)
LET Refresh&=@control("Button","<<< aktualisieren",$50010100 | $2000000,360,240,150,30,%Hwnd,2696,%Hinstance)
LET ICONHOLDER$="Computer"
Let IconHandle&=@LoadImage(%HINSTANCE,@ADDR(Iconholder$),$1,18,18,$0)
LET Refresh_Static&=@control("Static","",$50000003,120,5,18,18,Refresh&,2695,%Hinstance)
@Sendmessage(Refresh_Static&,$170,IconHandle&,0)
Usermessages $10
Repeat
Waitinput
Until %Umessage=$10
@Destroywindow(Refresh&)
Deleteobject IconHandle&
End
[/code:1:cd76674b36]


Baby-Klappe

Beitrag, 28.09.2006 13:23: [code:1:09acd4cac7]'Source wurde am 28.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
{$crq}
'{$debug}
cls
declare s$,ss$
decimals 0
s$="1.1"
ss$:="-1.1"
while 1
s$:=strMath.add(s$,1,0)
ss$:=strMath.add(ss$,1,1)
print s$,ss$
waitkey

wend
end
proc strMath.add
parameters s$,decpos&,plus%

declare p&,ol&

p&:=instr(".",s$)

case p& : s$:=del$(s$,p&,1)

ol&:=len(s$)

if plus%
s$:=.strmath.strInc(s$,decpos&)

case mid$(s$,1,1)=="-" : casenot len(translate$(del$(s$,1,1),"0","")) : s$:=del$(s$,1,1)

else

s$:=.strmath.strDec(s$,decpos&)

endif

if p&

s$:=ins$(".",s$,p&-(ol&-len(s$)))

endif

return s$
proc .strmath.strInc
parameters s$,p&
declare i&,op&
case s$=="-1" : return "0"
case mid$(s$,1,1)=="-" : return "-"+.strmath.strDec(del$(s$,1,1),p&)
op&:=p&
p&:=len(s$)-(p&-1)
casenot p& : return .strmath.strInc("0"+s$,op&)
i&:=val(mid$(s$,p&,1))
i&+
if i&<10
s$:=ins$(str$(i&),s$,p&)
s$:=del$(s$,p&+1,1)
else
s$:=ins$("0",s$,p&)
s$:=del$(s$,p&+1,1)
s$:=.strmath.strInc(s$,op&+1)
endif
return s$
endproc
proc .strmath.strDec
parameters s$,p&
declare i&,op&
case mid$(s$,1,1)=="-" : return "-"+.strmath.strInc(del$(s$,1,1),p&)
op&:=p&
p&:=len(s$)-(p&-1)
i&:=val(mid$(s$,p&,1))
i&-
if i&>-1
s$:=ins$(str$(i&),s$,p&)
s$:=del$(s$,p&+1,1)
else
if len(translate$(s$,"0",""))>0
i&:=9
s$:=ins$(str$(i&),s$,p&)
s$:=del$(s$,p&+1,1)
s$:=.strmath.strDec(s$,op&+1)
else
return "-"+del$(s$,len(s$),1)+"1"
endif
endif
return s$
endproc

endproc[/code:1:09acd4cac7]


Baby-Klappe

Beitrag, 28.09.2006 21:34: [code:1:a45262dd71]'Source wurde am 28.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
{$crq}
'kleiner blackwhite BMP to XprofanConverter.
decimals 0
declare s$
s$:="cls\n\n"
cls
loadbmp "C:\2.bmp",0,0;0
declare x&,y&,more&,sx&
for y&:=0 to %bmpy do begin
for x&:=0 to %bmpx do begin
ifnot getpixel(x&,y&)
ifnot more&
ifnot getpixel(x&+1,y&)
more&:=1
sx&:=x&
else
s$:=s$+"setpixel "+str$(x&)+","+str$(y&)+",0\n"
endif
else
if getpixel(x&+1,y&)
s$:=s$+"line "+str$(sx&)+","+str$(y&)+" - "+str$(x&+1)+","+str$(y&)+"\n"
more&:=0
endif
endif
endif
end

if more&

s$:=s$+"line "+str$(sx&)+","+str$(y&)+" - "+str$(x&+1)+","+str$(y&)+"\n"
more&:=0

endif

end
s$:=s$+"\n\nWaitKey\nEnd"
clearclip
putclip s$
end
[/code:1:a45262dd71]


Baby-Klappe

Beitrag, 28.09.2006 21:40: [code:1:8abe21f7fd]'Source wurde am 28.09.2006 in die Babyklappe auf XProfan.Com abgelegt:
{$crq}
'kleiner blackwhite BMP to XprofanConverter.
'bmp2pixel4okreaThumbs
decimals 0
declare s$,versatz$
versatz$:="-1,-1"
cls
loadbmp "C:\2.bmp",0,0;0
declare x&,y&,more&,sx&
for y&:=0 to %bmpy do begin
for x&:=0 to %bmpx do begin
ifnot getpixel(x&,y&)
ifnot more&
ifnot getpixel(x&+1,y&)
more&:=1
sx&:=x&
else
s$:=s$+".rpix "+str$(x&)+","+str$(y&)+"\t,"+versatz$+"\n"
endif
else
if getpixel(x&+1,y&)
s$:=s$+".rline "+str$(sx&)+","+str$(y&)+","+str$(x&+1)+","+str$(y&)+"\t,"+versatz$+"\n"
more&:=0
endif
endif
endif
end

if more&

s$:=s$+".rline "+str$(sx&)+","+str$(y&)+","+str$(x&+1)+","+str$(y&)+"\t,"+versatz$+"\n"
more&:=0

endif

end
clearclip
putclip s$
end
[/code:1:8abe21f7fd]


Baby-Klappe

Beitrag, 09.10.2006 20:47: [code:1:d9ca24d0e3]'Source wurde am 09.10.2006 in die Babyklappe auf XProfan.Com abgelegt:
'
' Buttons mal etwas anders (FA)
'
{$iq}
Def GetSysColor(1) !"USER32","GetSysColor"
Cls GetSysColor(15)
UseFont "MS Sans Serif",13,0,0,0,0
SetDialogFont 1
Control("BUTTON", "Button Nummer 1", $54010003, 10, 20, 160, 20, %hwnd, 2001, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 2", $54010303, 10, 40, 160, 20, %hwnd, 2002, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 3", $54010203, 10, 60, 160, 20, %hwnd, 2003, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 4", $54010023, 10, 100, 160, 20, %hwnd, 2004, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 5", $54010323, 10, 120, 160, 20, %hwnd, 2005, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 6", $54010223, 10, 140, 160, 20, %hwnd, 2006, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 7", $54030009, 10, 180, 160, 20, %hwnd, 2007, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 8", $54010309, 10, 200, 160, 20, %hwnd, 2008, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 9", $54010209, 10, 220, 160, 20, %hwnd, 2009, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 10", $54030029, 10, 260, 160, 20, %hwnd, 2010, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 11", $54010329, 10, 280, 160, 20, %hwnd, 2011, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 12", $54010229, 10, 300, 160, 20, %hwnd, 2012, %hInstance, $00000000)
Control("BUTTON", "Button Nummer 13", $54010003, 210, 20, 160, 20, %hwnd, 2013, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 14", $54010303, 210, 40, 160, 20, %hwnd, 2014, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 15", $54010203, 210, 60, 160, 20, %hwnd, 2015, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 16", $54010023, 210, 100, 160, 20, %hwnd, 2016, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 17", $54010323, 210, 120, 160, 20, %hwnd, 2017, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 18", $54010223, 210, 140, 160, 20, %hwnd, 2018, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 19", $54030009, 210, 180, 160, 20, %hwnd, 2019, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 20", $54010309, 210, 200, 160, 20, %hwnd, 2020, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 21", $54010209, 210, 220, 160, 20, %hwnd, 2021, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 22", $54030029, 210, 260, 160, 20, %hwnd, 2022, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 23", $54010329, 210, 280, 160, 20, %hwnd, 2023, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 24", $54010229, 210, 300, 160, 20, %hwnd, 2024, %hInstance, $00000001)
Control("BUTTON", "Button Nummer 25", $54010003, 410, 20, 160, 20, %hwnd, 2025, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 26", $54010303, 410, 40, 160, 20, %hwnd, 2026, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 27", $54010203, 410, 60, 160, 20, %hwnd, 2027, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 28", $54010023, 410, 100, 160, 20, %hwnd, 2028, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 29", $54010323, 410, 120, 160, 20, %hwnd, 2029, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 30", $54010223, 410, 140, 160, 20, %hwnd, 2030, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 31", $54030009, 410, 180, 160, 20, %hwnd, 2031, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 32", $54010309, 410, 200, 160, 20, %hwnd, 2032, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 33", $54010209, 410, 220, 160, 20, %hwnd, 2033, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 34", $54030029, 410, 260, 160, 20, %hwnd, 2034, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 35", $54010329, 410, 280, 160, 20, %hwnd, 2035, %hInstance, $00000200)
Control("BUTTON", "Button Nummer 36", $54010229, 410, 300, 160, 20, %hwnd, 2036, %hInstance, $00000200)
While 1
WaitInput
Case %key=2:BREAK
EndWhile
End[/code:1:d9ca24d0e3]


Baby-Klappe

Beitrag, 16.10.2006 19:22: [code:1:7910e42d73]'Source wurde am 16.10.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc setSubStr(s$,n&,d$,ns$) //XProfan10
return ins$(ns$,del$(s$,n&,1,d$),n&,d$)

endproc
proc setSubStr(Quelle$,WortNr&,Trenner$,NeuesWort$)//XProfan10
return ins$(NeuesWort$,del$(Quelle$,WortNr&,1,Trenner$),WortNr&,Trenner$)
endproc
[/code:1:7910e42d73] :P


Baby-Klappe

Beitrag, 26.10.2006 21:52: [code:1:a839e9544d]'Source wurde am 26.10.2006 in die Babyklappe auf XProfan.Com abgelegt:
http://xprofan.com/hilfe/sheet/xpse/[/code:1:a839e9544d]


Baby-Klappe

Beitrag, 30.10.2006 19:31: [code:1:700f8ea751]'Source wurde am 30.10.2006 in die Babyklappe auf XProfan.Com abgelegt:
cls
ogl("init",%hwnd,0.0,0.0,0.0,1)
oGL("Clear")
'--Cam:
oGL("Origin", 4.866667, 2.866667, -35.2)
oGL("Rotate", 290, -785, 0)
oGL("Move", 0, -1, 0)
'--Objects:
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",0,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",15,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",30,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",45,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",60,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",75,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",90,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",105,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",120,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",135,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",150,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",165,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",180,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",195,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",210,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",225,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",240,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",255,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",270,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",285,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",300,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",315,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",330,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("Pop")
ogl("Push")
ogl("Move",0,0,0)
ogl("rotate",345,0,0)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
ogl("move",0,5,0)
ogl("cuboid",2,2,2)
'--
ogl("show")
waitinput
end[/code:1:700f8ea751]


Baby-Klappe

Beitrag, 06.11.2006 18:36: [code:1:cf3bb52f56]'Source wurde am 06.11.2006 in die Babyklappe auf XProfan.Com abgelegt:
'{ Kommandozeile aufschlüsseln
$H Windows.ph
Declare ArgC%, ArgV$[15], ArgLine$, ArgExe$, ArgModul$, ArgTyp$
ArgExe$ = Par$(0)
' ArgC% - Anzahl der Parameter
' ArgV$[15] - 1..15 Parameter
' ArgLine$ - die Parameter 1 - 15 (ohne ArgExe$ und ArgModul$)
' ArgExe$ - Name der EXE-Datei (PROFAN / PRFRUN32 / eig.PgmName)
' ArgModul$ - Modulname (bei Interpreter: .prf, bei Runtime: .prc, bei EXE: <leer>)
' ArgTyp$ - "Interpreter" / "Runtime" / "Programm"
Proc CommandLine$
' Mittels CommandLine$() werden die obigen Variablen bestückt.
ArgC% = %ParCount
Clear ArgV$[], ArgLine$
'ArgExe$ = Par$(0)
ArgV$[0] = ArgExe$
If (ArgC% > 0) and (InStr("PROFAN.EXE",Upper$(ArgExe$)) > 0) ' evtl. an Version anpassen
ArgTyp$ = "Interpreter"
ArgModul$ = Par$(1)
ElseIf (ArgC% > 0) and (InStr("PRFRUN32.EXE",Upper$(ArgExe$)) > 0) ' evtl. an runTime anpassen
ArgTyp$ = "Runtime"
ArgModul$ = Par$(1)
Else
ArgTyp$ = "Programm"
Clear ArgModul$
EndIf
Select ArgTyp$
CaseOf "Interpreter","Runtime"
WhileLoop 2,ArgC%
ArgV$[&loop-1] = Par$(&loop)
ArgLine$ = ArgLine$ + " " + Par$(&loop)
EndWhile
Case ArgC% : Dec ArgC%
CaseOf "Programm"
WhileLoop ArgC%
ArgV$[&loop] = Par$(&loop)
ArgLine$ = ArgLine$ + " " + Par$(&loop)
EndWhile
EndSelect
ArgLine$ = Trim$(ArgLine$)
Return 0
EndProc
Proc SetCommandLine$
' Mit SetCommandLine$( Parameterstring$ ) wird die Kommandozeile neu definiert.
' (ArgV(0) wird automatisch hinzugefügt)
Parameters CmdLine$
Declare CmdLinePtr&
CmdLinePtr& = ~GetCommandLine()
String CmdLinePtr&, 0 = ArgExe$ + " " + CmdLine$
CommandLine$()
Return 0
EndProc
Proc AddCommandLine$
' Mit AddCommandLine$( Parameterstring$ ) wird die bestehende Kommandozeile erweitert.
Parameters CmdLine$
Declare CmdLinePtr&
CmdLinePtr& = ~GetCommandLine()
String CmdLinePtr&, 0 = String$(CmdLinePtr&, 0) + " " + CmdLine$
CommandLine$()
Return 0
EndProc
Proc ShowCommandLineVars
Print
Print "--------Kommandozeile--------------------------"
Print "ArgC%..:", ArgC%
Print "ArgTyp.:", ArgTyp$
Print "EXE....:", ArgExe$
Print "Modul..:", ArgModul$
WhileLoop ArgC%
Print "Var ";Format$("00",&loop);":", ArgV$[&loop]
EndWhile
Print
Print "ParLine:", ArgLine$
Print "--------Kommandozeile-Ende---------------------"
Print
Return 0
EndProc
'}
'
' ' Test
' cls
' CommandLine$()
' ShowCommandLineVars()
'
' AddCommandLine$( "drei zwei eins" )
' ShowCommandLineVars()
'
' WaitKey
' End
'
[/code:1:cf3bb52f56]


Baby-Klappe

Beitrag, 09.11.2006 17:47: [code:1:10bc7d4a1b]!'Source wurde am 09.11.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc LoadTGA(string fileName)
casenot fileexists(fileName) : return false

long fSiz:=filesize(fileName)

case (fSiz<18) : return false /*headerSize*/

mem mem:=fSiz

long bytesRead:=blockread(fileName,mem,0,fSiz)

casenot (bytesRead==fSiz) : return false

int FileType:=byte(mem,0)
int ColorMapType:=byte(mem,1)
int ImageType:=byte(mem,2)
long XX:=byte(mem,12)+byte(mem,13)*256
long YY:=byte(mem,14)+byte(mem,15)*256
long BPP:=byte(mem,16)
long ImageInfo:=byte(mem,17)
long ImageSize:=XX*YY*(BPP\8)

/*
print "FileType",fileType
print "ColorMapType",ColorMapType
print "ImageType",ImageType
print "Width",XX
print "Height",YY
print "BPP",BPP
print "ImageSize",ImageSize
*/

casenot (ImageType==2) : return false //isnt 32bit rgb uncompressed
casenot (ColorMapType==0) : return false //no support for colormapped tgas
casenot (BPP==32) : return false //only support 32bit colordepth

long x,y,i,c
int r,g,b,a
yy-
xx-

for y:=yy downto 0 do begin

for x=0 to xx do begin

c:=i*4+18

b:=byte(mem,c)
g:=byte(mem,c+1)
r:=byte(mem,c+2)
a:=byte(mem,c+3)

setpixel x,y,rgb(r,g,b)

i+

end
end

dispose mem

return true

endproc
[/code:1:10bc7d4a1b]


Baby-Klappe

Beitrag, 09.11.2006 18:09: [code:1:1f4cf42acd]'Source wurde am 09.11.2006 in die Babyklappe auf XProfan.Com abgelegt:
'{$cleq}
cls
ogl("init",%hwnd,0.0,0.0,0.0,0)
'f& = oGL("BITMAPFONT") Der aktuell mit USEFONT eingestellte Font wird als Bitmapfont (2D) unter der Nummer f& bereitgestellt
ogl("glBindTexture",GL_TEXTURE_2D,1);
ogl("glTexEnvi",GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE)
ogl("glTexParameteri",GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR)
ogl("glTexParameteri",GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR)
mem pdata=64*64*4
LoadTGA("Clip1.tga")
ogl("gluBuild2DMipmaps",GL_TEXTURE_2D, GL_RGBA, 64, 64, GL_RGBA, GL_UNSIGNED_BYTE, pdata)

oGL("Clear")
ogl("move",0,0,-5)
ogl("texture",1,1)
ogl("cuboid",1,1,1)
'ogl("gluBuild2DMipmaps")
ogl("show")
waitkey
end
proc LoadTGA(string fileName)
casenot fileexists(fileName) : return false

long fSiz:=filesize(fileName)

case (fSiz<18/*headerSize*/) : return false

mem mem:=fSiz

long bytesRead:=blockread(fileName,mem,0,fSiz)

casenot (bytesRead==fSiz) : return false

int FileType:=byte(mem,0)
int ColorMapType:=byte(mem,1)
int ImageType:=byte(mem,2)
long XX:=byte(mem,12)+byte(mem,13)*256
long YY:=byte(mem,14)+byte(mem,15)*256
long BPP:=byte(mem,16)
long ImageInfo:=byte(mem,17)
long ImageSize:=XX*YY*(BPP\8)

/*
print "FileType",fileType
print "ColorMapType",ColorMapType
print "ImageType",ImageType
print "Width",XX
print "Height",YY
print "BPP",BPP
print "ImageSize",ImageSize
*/

casenot (ImageType==2) : return false //isnt 32bit rgb uncompressed
casenot (ColorMapType==0) : return false //no support for colormapped tgas
casenot (BPP==32) : return false //only support 32bit colordepth

long x,y,front,back,i,c
int r,g,b,a
yy-
xx-

for y:=yy downto 0 do begin

for x=0 to xx do begin

c:=i*4+18

b:=byte(mem,c)
g:=byte(mem,c+1)
r:=byte(mem,c+2)
a:=byte(mem,c+3)

c:=i*4

setpixel x,y,rgb(r,g,b)

byte pdata#,c=r
byte pdata#,c+1=g
byte pdata#,c+2=b
byte pdata#,c+3=a

i+

end
end

dispose mem

return true

endproc
[/code:1:1f4cf42acd]


Baby-Klappe

Beitrag, 09.11.2006 18:16: [code:1:b22eadab88]'Source wurde am 09.11.2006 in die Babyklappe auf XProfan.Com abgelegt:
// thats fantastic!
{$cleq}
cls
ogl("init",%hwnd,0.0,0.0,0.0,1)
'f& = oGL("BITMAPFONT") Der aktuell mit USEFONT eingestellte Font wird als Bitmapfont (2D) unter der Nummer f& bereitgestellt
ogl("glBindTexture",GL_TEXTURE_2D,1);
ogl("glEnable",GL_ALPHA_TEST)
ogl("glAlphaFunc",GL_GREATER, 0.1)
ogl("glTexEnvi",GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE)
ogl("glTexParameteri",GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR)
ogl("glTexParameteri",GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR)
mem pdata=64*64*4
LoadTGA("Clip1.tga")
ogl("gluBuild2DMipmaps",GL_TEXTURE_2D, GL_RGBA, 64, 64, GL_RGBA, GL_UNSIGNED_BYTE, pdata)

while 1
oGL("Clear")
ogl("move",0,0,-5)
ogl("texture",1,1)
ogl("rotate",gettickcount/100,mousex/10,mousey/10)
ogl("cuboid",1,1,1)
'ogl("gluBuild2DMipmaps")
ogl("show")
case mousepressed : break
wend
dispose pdata
end
proc LoadTGA(string fileName)
casenot fileexists(fileName) : return false

long fSiz:=filesize(fileName)

case (fSiz<18/*headerSize*/) : return false

mem mem:=fSiz

long bytesRead:=blockread(fileName,mem,0,fSiz)

casenot (bytesRead==fSiz) : return false

int FileType:=byte(mem,0)
int ColorMapType:=byte(mem,1)
int ImageType:=byte(mem,2)
long XX:=byte(mem,12)+byte(mem,13)*256
long YY:=byte(mem,14)+byte(mem,15)*256
long BPP:=byte(mem,16)
long ImageInfo:=byte(mem,17)
long ImageSize:=XX*YY*(BPP\8)

/*
print "FileType",fileType
print "ColorMapType",ColorMapType
print "ImageType",ImageType
print "Width",XX
print "Height",YY
print "BPP",BPP
print "ImageSize",ImageSize
*/

casenot (ImageType==2) : return false //isnt 32bit rgb uncompressed
casenot (ColorMapType==0) : return false //no support for colormapped tgas
casenot (BPP==32) : return false //only support 32bit colordepth

long x,y,front,back,i,c
int r,g,b,a
yy-
xx-

for y:=yy downto 0 do begin

for x=0 to xx do begin

c:=i*4+18

b:=byte(mem,c)
g:=byte(mem,c+1)
r:=byte(mem,c+2)
a:=byte(mem,c+3)

c:=i*4

setpixel x,y,rgb(r,g,b)

byte pdata#,c=r
byte pdata#,c+1=g
byte pdata#,c+2=b
byte pdata#,c+3=(r+g+b)\3

i+

end
end

dispose mem

return true

endproc
[/code:1:b22eadab88]


Baby-Klappe

Beitrag, 03.12.2006 17:38: [code:1:a399e707e2]'Source wurde am 03.12.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc set_local_date(int Jahr, Monat, Tag)

mem datum=16
GetLocalTime(Datum)
word Datum#, 0 = Jahr%
word Datum#, 2 = Monat%
word Datum#, 6 = Tag%
SetLocalTime(Datum)

dispose datum

endproc
proc set_local_time(int Stunde, Minute, Sekunde, Millisekunde)

mem datum=16
GetLocalTime(Datum)
word Datum#, 8 = Stunde
word Datum#, 10 = Minute
word Datum#, 12 = Sekunde
word Datum#, 14 = Millisekunde
SetLocalTime(Datum)

dispose datum
endproc[/code:1:a399e707e2]


Baby-Klappe

Beitrag, 06.12.2006 18:22: [code:1:be98d9c2dc]'Source wurde am 06.12.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc CreateWindowByClient
parameters 1&,2&,3&,4&,5&
declare h&,c#
dim c#,16
if 5&
1& = (%MaxX/2)-(3&/2)
2& = (%MaxY/2)-(4&/2)
endif
window %maxx+1&,2&-3&,4&
h&=%hwnd
external("USER32","GetClientRect",h&,c#)
setwindowpos h& = 1&,2&-(3&+(3&-long(c#,8))),(4&+(4&-long(c#,12)));0
dispose c#
endproc
CreateWindowByClient(0,0,300,300,1) 'Par5: 1=zentriert
waitkey[/code:1:be98d9c2dc]


Baby-Klappe

Beitrag, 06.12.2006 19:52: [code:1:6924fce022]'Source wurde am 06.12.2006 in die Babyklappe auf XProfan.Com abgelegt:
[code]!Proc RTFAddLine
' fügt eine neue Zeile ans Ende des Textes ein
Parameters hWnd&, Text$
Text$ = Text$ + Chr$(10)
SendMessage(hWnd&, 177, $FFFF, $FFFF) ' EM_SETSEL
SendMessage(hWnd&, 194, 0, Addr(Text$)) ' EM_REPLACESEL
EndProc[/code][/code:1:6924fce022]


Baby-Klappe

Beitrag, 11.12.2006 23:19: [code:1:aa9e0cd5f0]'Source wurde am 11.12.2006 in die Babyklappe auf XProfan.Com abgelegt:
{$cleq}
cls
LineDDA(0,0,256,256,procaddr(linesetpx,3),0)
waitkey
end
proc linesetpx(long x,y,unused)
//case (x\2*2==x) : setpixel x,y,0

setpixel x,y,rgb(x,y,0)

return false

endproc[/code:1:aa9e0cd5f0]


Baby-Klappe

Beitrag, 12.12.2006 00:54: [code:1:26c096b5f9]'Source wurde am 11.12.2006 in die Babyklappe auf XProfan.Com abgelegt:
blockwrite und read sollten auch .h& erlauben...[/code:1:26c096b5f9]


Baby-Klappe

Beitrag, 21.12.2006 19:41: [code:1:e4bae9d43b]'Source wurde am 21.12.2006 in die Babyklappe auf XProfan.Com abgelegt:
proc memoryBitMapExists
startpaint -1

long c:=getpixel(0,0)

endpaint

return if(c==-1,false,true)

endproc[/code:1:e4bae9d43b]


Baby-Klappe

Beitrag, 21.12.2006 19:59: [code:1:725590df79]'Source wurde am 21.12.2006 in die Babyklappe auf XProfan.Com abgelegt:
{$cleq}
cls
long mystatic1:=cc.newColorStatic(hwnd,rgb(255,0,0),10,10,100,100)
long mystatic2:=cc.newColorStatic(hwnd,rgb(0,0,255),110,10,100,100)
waitkey
end
proc cc.newColorStatic(long parent,col,x,y,xx,yy)
long h:=Control("STATIC","",$5400010E,x,y,xx,yy,parent,$7918,Hinstance)

string sid:=tempdir+"\"+str$(gettickcount)

ifnot memoryBitMapExists()

mcls 1,1,col
startpaint -1
savebmp sid,0,0 - 1,1
endpaint

else

startpaint -1
long c:=getpixel(0,0)
setpixel 0,0,col
savebmp sid,0,0 - 1,1
setpixel 0,0,c
endpaint

endif

long img:=loadimageA(hinstance,addr(sid),IMAGE_BITMAP,1,1,$50)
Sendmessage(h,$172,0,img)
setwindowpos h=x,y - xx,yy;0

int fh:=assign(sid)
erase fh
assign fh,""
return h

Endproc
proc memoryBitMapExists
startpaint -1

long c:=getpixel(0,0)

endpaint

return if(c==-1,false,true)

endproc[/code:1:725590df79]


Dies ist die Offlinevariante vom Thread [Babyklappe-Eingang].

Valid CSS!

©2006 XProfan.Com