Page 1 of 1
Posted: Mon Mar 17, 2003 6:46 pm
by BackupUser
Restored from previous forum. Originally posted by Passant.
Please try this code (I have allways graphic-errors)...
You only have to put a jpeg ("test.jpg") in the same path.
InitSprite()
InitKeyboard()
UseJPEGImageDecoder()
OpenScreen (800,600,16,"test")
LoadSprite(0,"test.jpg" ,0)
Repeat
ExamineKeyboard()
FlipBuffers()
DisplaySprite(0,100,100)
Until KeyboardPushed(#PB_Key_Escape)
End
Posted: Mon Mar 17, 2003 7:33 pm
by BackupUser
Restored from previous forum. Originally posted by tranquil.
Originally posted by Passant
Please try this code (I have allways graphic-errors)...
You only have to put a jpeg ("test.jpg") in the same path.
InitSprite()
InitKeyboard()
UseJPEGImageDecoder()
OpenScreen (800,600,16,"test")
LoadSprite(0,"test.jpg" ,0)
Repeat
ExamineKeyboard()
FlipBuffers()
DisplaySprite(0,100,100)
Until KeyboardPushed(#PB_Key_Escape)
End
Never thought about that Command. Did you found it in the docs!? Is that an official command?
Mike
Tranquilizer/ Secretly!
http://www.secretly.de
Registred PureBasic User
System: Windows 2000 Server, 512 MB Ram, GeForce4200 TI 128 MB DDR, Hercules Theater 6.1 DTS Sound
System 2: Mobile Pentium 4 2.4GHz 512 MB DDR GeForce4 420-32, Windows XP Home
Posted: Mon Mar 17, 2003 7:36 pm
by BackupUser
Restored from previous forum. Originally posted by plouf.
YEp i get corrupted images too
i also have problems with all LoadSprite
fuctions but i can determine the exact reason ...
Christos
Posted: Mon Mar 17, 2003 7:37 pm
by BackupUser
Restored from previous forum. Originally posted by ebs.
Passant,
It doesn't work for me either, but using a bit depth of 32 instead of 16 works.
Eric
Originally posted by Passant
Please try this code (I have allways graphic-errors)...
You only have to put a jpeg ("test.jpg") in the same path.
InitSprite()
InitKeyboard()
UseJPEGImageDecoder()
OpenScreen (800,600,16,"test")
LoadSprite(0,"test.jpg" ,0)
Repeat
ExamineKeyboard()
FlipBuffers()
DisplaySprite(0,100,100)
Until KeyboardPushed(#PB_Key_Escape)
End
Posted: Mon Mar 17, 2003 7:40 pm
by BackupUser
Restored from previous forum. Originally posted by Kendrel.
tranquil: have you had a look at pb 3.60?! its a new command
and the example also gives me garbage only... image is not displayed correct... i wonder why this didnt happen when the commands were tested...
Posted: Mon Mar 17, 2003 7:42 pm
by BackupUser
Restored from previous forum. Originally posted by Kendrel.
it does work for me when you use 32bit mode instead of 16, but then again when i move the mouse ill see my windows mouse cursor and such... i dont think this is supposed to happen huh?!
Posted: Mon Mar 17, 2003 8:56 pm
by BackupUser
Restored from previous forum. Originally posted by LJ.
I am under the impression that the reason your code does not work is that you need DirectX 7 installed on your computer. The JPEG command is part of the libraries that use DirectX 7 or greater installed on the host machine.
Posted: Mon Mar 17, 2003 8:58 pm
by BackupUser
Restored from previous forum. Originally posted by Passant.
32 bit-Mode --> That's it
Thank you for your posts
Posted: Mon Mar 17, 2003 9:47 pm
by BackupUser
Restored from previous forum. Originally posted by fred.
LJ: nop, the JPEG command works for Image and Sprite and doesn't requiers DX at all. I've fixed the lib for 16bits mode, get it at:
http://www.purebasic.com/update/Sprite
Tell me if it works..
Fred - AlphaSND
Posted: Tue Mar 18, 2003 1:31 am
by BackupUser
Restored from previous forum. Originally posted by LJ.
Fred: You da man!!!