Dec 3 2004, 01:52 AM
Post
#1
|
|
|
Group: Members Posts: 153 Joined: 5-January 04 Member No.: 1,081 |
I've been looking at the kernel source for the SL6000's framebuffer driver, and I can see an API provided to access the hardware acceleration - but it's documentation is pretty much zero
The only example of it being actually used in the driver itself is the tc6393_clear_screen() function, that uses the hardware rectangle fill to clear the screen. There's a very interesting looking command set provided in the tc6393fb.h file, and an ioctl provided to pass lists of commands to the graphics hardware for processing - but the actual commands (although defined) aren't actually documented The clear screen example in the driver is static u32 cmd[6]; cmd[0] = PXAIO_COMDI_DSADR|PXAIO_COMDD_DSADR(((int)remapped_fbuf)); cmd[1] = PXAIO_COMDI_DHPIX|PXAIO_COMDD_DHPIX(xres - 1); cmd[2] = PXAIO_COMDI_DVPIX|PXAIO_COMDD_DVPIX(yres - 1); cmd[3] = PXAIO_COMDI_FILL|PXAIO_COMDD_FILL(0xffff); cmd[4] = PXAIO_COMDI_FLGO; Using the ioctl interface to the framebuffer, this would be: static u32 cmd[6]; cmd[0] = 5; cmd[1] = PXAIO_COMDI_DSADR|PXAIO_COMDD_DSADR(((int)remapped_fbuf)); cmd[2] = PXAIO_COMDI_DHPIX|PXAIO_COMDD_DHPIX(xres - 1); cmd[3] = PXAIO_COMDI_DVPIX|PXAIO_COMDD_DVPIX(yres - 1); cmd[4] = PXAIO_COMDI_FILL|PXAIO_COMDD_FILL(0xffff); cmd[5] = PXAIO_COMDI_FLGO; ioctl(fbHandle,TC6393FB_ACC_CMD_WRITE,cmd); and then I'm guessing that if you want to make sure it's completed before carrying on, you can use: ioctl(fbHandle,TC6393FB_ACC_SYNC,0); But the tc6393 looks like it can do blitting as well....I've no idea what the rest of the command API def's actually do though? And glory be - Toshiba haven't released a datasheet for the chip When I eventually get my hands on my SL6000 (my wife's hidden it 'til Christmas) I'll start trying some of the commands, see if I can work it out through trial & error.....unless someone else beats me to it of course SDL would go much quicker with a bit of the ol' hardware accel... |
|
|
|
![]() |
Nov 17 2005, 05:51 PM
Post
#2
|
|
|
Group: Members Posts: 577 Joined: 17-March 04 Member No.: 2,365 |
without the chip technical manual, no hope.
|
|
|
|
Nov 28 2005, 02:28 AM
Post
#3
|
|
|
Group: Members Posts: 5 Joined: 28-November 05 Member No.: 8,626 |
Sharp's tc6393fb.h has enough information to experiment. First, I'd try modifying the fill command to draw colored boxes on the screen. This is very useful for accelerating window managers, as they tend to draw the backing color, then the objects on top. The source copy would be great for moving windows, scrolling windows, scrolling the console, and drawing console characters.
The TC6393 has 1MB of video memory. The default 640x480x16bit mode only uses 600kB, leaving 424kB for console fonts, bitmaps, etc, for source copy. Also, 424kB is enough for one large 528x400 buffer. With a custom mplayer plugin, mplayer can render to that off-screen buffer, then StretchBLT the buffer to the 640x480 screen. It looks like StretchBLT has vertical reverse and horizontal reverse options, too, so you can flip horizontal, or flip vertical, or rotate the video 180 degrees in hardware. I'm working on the 2.6 kernel at the moment, and I'll work on video acceleration at some point (it's a low priority, so it could be a while). If someone wants to experiment and help out, that'd be even better. =) The TC6393's LCD controller has five accelration commands: PXAIO_COMDI_CMGO - Cursor Move? PXAIO_COMDI_FLGO - Fill PXAIO_COMDI_SCGO - Source Copy PXAIO_COMDI_SBGO - StretchBLT PXAIO_COMDI_LDGO - Line Draw Out of the set commands, we can group by ones that take a pixel color as a paremeter: PXAIO_COMDI_FILL - fill color PXAIO_COMDI_TCLOR - transparent color for Source Copy ones that take a memory address as a parameter: PXAIO_COMDI_CSADR - cursor screen address? PXAIO_COMDI_PSADR - physical screen address? PXAIO_COMDI_POADR - physical offset address? PXAIO_COMDI_DSADR - destination screen address? PXAIO_COMDI_SSADR - source screen address? and ones that take a x or y offset or pixel count as a parameter: PXAIO_COMDI_CHPIX - cursor horizontal pixels? PXAIO_COMDI_CVPIX - cursor vertical pixels? PXAIO_COMDI_PHPIX - physical horizontal pixels? PXAIO_COMDI_PVPIX - physical vertical pixels? PXAIO_COMDI_PHOFS - physical horizontal offset? PXAIO_COMDI_PVOFS - physical vertical offset? PXAIO_COMDI_DHPIX - destination horizontal pixels PXAIO_COMDI_DVPIX - destination vertical pixels PXAIO_COMDI_SHPIX - source horizontal pixels? PXAIO_COMDI_SVPIX - source vertical pixels? |
|
|
|
Nov 28 2005, 02:40 AM
Post
#4
|
|
![]() Group: Admin Posts: 3,277 Joined: 29-July 04 From: Cambridge, England Member No.: 4,149 |
QUOTE(mahadri @ Nov 28 2005, 11:28 AM) this sounds very promising. Perhaps with the re-release of the 6000 as a windows mobile device more information will come out too. Whilst I'd love to help, I'm only running kernel 2.4 on the Guylhem ROM, sorry :-( I've also no experience at actually writing kernel modules. But, I'd be willing to give back-porting the driver to 2.4.x a shot, or even being a guinea pig if I can. If nothing else, be encouraged that there are lots of eager people waiting for faster video drivers for their 6000! Paul |
|
|
|
Nov 28 2005, 03:10 AM
Post
#5
|
|
|
Group: Members Posts: 5 Joined: 28-November 05 Member No.: 8,626 |
QUOTE(speculatrix @ Nov 28 2005, 05:40 AM) this sounds very promising. Perhaps with the re-release of the 6000 as a windows mobile device more information will come out too. I could reverse-engineer those drivers if they implement a feature we like.QUOTE Whilst I'd love to help, I'm only running kernel 2.4 on the Guylhem ROM, sorry :-( The Sharp kernel exports an ioctl for video acceleration. I doubt any Sharp-based ROM removed this ioctl, so you can test from userspace. You just need a cross-compiler to compile tosaacc.c. It's a simple program that uses the Fill command to clear the screen to a color specified on the command line.Usage: tosaacc <color in hex> Example: tosaacc 48c0 If there's enough demand from people without cross-compilers, I can modify this program to read accelerator commands from stdin so I can distribute a binary version. It's not as nice, though, as you can't use Sharp's #defines and would have to write all commands in hex. |
|
|
|
cwaig Sl6000 Hardware Accelerated Display? Dec 3 2004, 01:52 AM
GoLinux Is this the same device?
http://www.mnementh.co.u... Dec 4 2004, 09:24 AM
cwaig I believe the part number is TC6393XB - there... Dec 4 2004, 10:30 AM
guylhem That would be a sweet addon to libsdl Dec 5 2004, 07:25 AM
GoLinux cwaig,
the information you can find at the link I... Dec 6 2004, 10:38 PM
psycoman asny news about TC6393XB video chip ? Jan 2 2005, 10:02 AM
GoLinux Not yet... I only found this guy who wrote a drive... Jan 3 2005, 01:38 PM
psycoman yeap, i send a email to this guy, he will send a p... Jan 4 2005, 02:43 AM
jcabrer QUOTE(psycoman @ Jan 4 2005, 03:43 AM)yeap, i... Jan 4 2006, 05:09 PM
speculatrix QUOTE(psycoman @ Jan 4 2005, 11:43 AM)yeap, i... Jan 24 2006, 06:09 AM
psycoman i get with ion, one documentation about the chip.
... Jan 5 2005, 05:29 AM
cwaig Has anyone made any progress with this (or seen th... Jan 17 2005, 12:46 PM
seed any new about the TC6393XB video chip ? do someone... Apr 16 2005, 11:01 AM
xjqian QUOTE(seed @ Apr 16 2005, 02:01 PM)do someone... Apr 16 2005, 03:44 PM
seed QUOTE(xjqian @ Apr 16 2005, 11:44 PM)QUOTE(se... Apr 16 2005, 05:22 PM
xjqian QUOTE(seed @ Apr 16 2005, 08:22 PM)QUOTE(xjqi... Apr 17 2005, 10:52 AM
seed [/quote]
not sure about c1k and c3k. but worse tha... Apr 17 2005, 01:51 PM
guylhem cwaig, did you got the docs I sent ?
Any progress... Apr 17 2005, 11:53 AM
seed any new about this Jun 12 2005, 07:13 PM
the_oak Any new developments in video hardware acceleratio... Jul 30 2005, 10:04 AM
speculatrix bump! Nov 16 2005, 02:44 PM
speculatrix p.s. and I'll gladly contribute to a beer fund... Nov 28 2005, 02:41 AM
guylhem Hello
By any chance, would you have the chip tech... Dec 2 2005, 03:34 AM
xenophobe QUOTESharp's tc6393fb.h has enough information... Dec 8 2005, 08:15 AM
jcabrer My first response from Toshiba is displayed below.... Jan 5 2006, 09:49 AM
speculatrix Just to note that the MSDN site has a comment abou... Jan 5 2006, 01:33 PM
jcabrer QUOTE(speculatrix @ Jan 5 2006, 02:33 PM)Just... Jan 5 2006, 02:20 PM
speculatrix QUOTE(jcabrer @ Jan 5 2006, 11:20 PM)QUOTE(sp... Jan 5 2006, 03:56 PM
jcabrer Well, it's not the TC6393XB, but it is VERY CL... Jan 5 2006, 03:03 PM
jgardia QUOTE(jcabrer @ Jan 5 2006, 11:03 PM)Well, it... Jan 5 2006, 03:51 PM

speculatrix QUOTE(jgardia @ Jan 6 2006, 12:51 AM)group of... Jan 5 2006, 03:57 PM

jgardia QUOTE(speculatrix @ Jan 5 2006, 11:57 PM)QUOT... Jan 5 2006, 04:17 PM
dirk QUOTE(jcabrer @ Jan 6 2006, 12:03 AM)Well, it... Jan 5 2006, 11:27 PM
speculatrix looks quite useful, albeit it's a hardware ref... Jan 5 2006, 03:45 PM
jcabrer Ok. I don't think Toshiba is going to give me... Jan 6 2006, 10:55 AM
jcabrer Looks like I spoke too soon.
QUOTEHi John,
We... Jan 6 2006, 03:42 PM
jcabrer And here is the final nail in the coffin. The tec... Jan 18 2006, 04:41 PM
DrWowe I'm quite confident that, given some time, eve... Jan 18 2006, 09:22 PM
speculatrix progress seems quite slow on this... I am really r... Jan 23 2006, 03:32 PM
xenophobe I had achieve some more progress in graphics accel... Jan 24 2006, 05:30 AM
xenophobe One more thing about Tosa acceleration.
If you tak... Jan 24 2006, 05:42 AM
speculatrix any news at all on this.. even a slightly improved... Apr 9 2006, 02:33 PM
speculatrix I now work in the science park in Cambridge, and t... Jun 5 2006, 12:48 PM
GoLinux Hi guys,
I'm afraid it might only be about th... Oct 29 2006, 07:33 PM
speculatrix QUOTE(GoLinux @ Oct 30 2006, 04:33 AM)Hi guys... Oct 30 2006, 02:45 AM
sdjf I have found the Tosa ROM 1.12 to be extremely slo... Aug 1 2008, 06:26 AM
speculatrix QUOTE(sdjf @ Aug 1 2008, 03:26 PM) I have... Aug 1 2008, 06:57 AM
sdjf Uh, have done neither AFAIK but I'll go off an... Aug 3 2008, 03:33 AM
the_oak Mine has never been slow switching between already... Aug 3 2008, 05:39 AM
sdjf yeah, did that first thing I'm afraid of gett... Aug 3 2008, 01:50 PM![]() ![]() |
|
Lo-Fi Version | Time is now: 26th May 2013 - 01:35 AM |