Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
gfxlib source
#1
I need to build a sub that will scale an image. I can do that pretty easily, however I need it to be FAST. For loops are just too slow, I remember hearing that FB's GET and PUT routines were written in assembly and are much faster than anything I could write. What I want to do is insert that assembly code in an inline assembly block and tweak it to do what I want it to do. Does anybody know where the source code for it is? I searched Freebasic.net and couldn't find it.

Alternativly does anybody have a superfast image scaling program?
f you play a Microsoft CD backwards you can hear demonic voices. The scary part is that if you play it forwards it installs Windows.
Reply
#2
No, they're written in C, and the source (v0.15b) is available at:

http://www.freebasic.net/index.php/detai...y=src&id=1

My usual advice is to profile and make sure you'e not trying to prematurely optimize, or are optimizing the wrong thing.

Have fun.
stylin:
Reply
#3
D.J. Peters posted this code some days ago, you may find it useful
http://www.freebasic.net/forum/viewtopic.php?t=2441
Antoni
Reply
#4
the blitters of the gfx lib are written in assembler ( the core of them ). i can't browse the cvs on sourceforge currently so download the source with the cvs client of your choice and search for .s files. i can't remember the names of the procedures but have a look for MMX and the like
quote="NecrosIhsan"]
[Image: yagl1.png]
[/quote]
Reply
#5
Ah yes, I guess I wasn't sure what you were asking. You're going to want to take a look at:
Code:
/FreeBASIC/src/gfxlib2
   libfb_gfx_blitter_mmx.s
   libfb_gfx_put_mmx.s
   libfb_gfx_mmx.s
stylin:
Reply
#6
http://forum.qbasicnews.com/viewtopic.ph...810#130810
Is it to slow?

Joshy
sorry about my english
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)