Registriert: Do Dez 05, 2002 10:35 Beiträge: 4234 Wohnort: Dortmund
One of the mayor problem is the small width of 512. If the width is getting smaller the Image/Webpage gets much higher. And i think the size is limited to 32768. Max pissible 16 Bit signed Integer.
Faster copy you can do with simple move or put the scanline pointer directlly into glTexImage. This you can do if you dont need to splitt the TBitmap vertically. But beware the TBitmap normally are bottom up so the last scanline is the first in the memory. May be you must flip your texturecoord vertically but so you can put it directlly into the texture. To check the direction of the bitmap get the first and last (hight -1) scanline and check which one is smaller than the other. So you can decide if it's really bottom up.
The method to copy it every time the user scrolls is not perfect but this only will happen once. So one frame will be slower than other and this is okay. Not perfect but okay if the size of one texture is enough.
PS: If the texture was allready allocated you should use glTexSubImage. Because its much faster than glTexImage.
I must admit I'm now quite pleased with what I've got here:
The main article can be scrolled up and down using the MCE remote buttons - Channel Up / Channel down for page jumps, cursors for smaller jumps. It looks OK and works really well. It successfully pulls back Wikipedia articles for most artists I've come across - it didn't work for Madonna, The Beatles and a few others who have very large Wikipedia articles. I guess that I could make the width of the Browser wider so that the resulting BMP is 1,024 pixels wide instead of 512 pixels but that would probably make the text a lot less readable on a 37" LCD from across the room.
Unless I came up with some fancy zooming technique like on the PS3 browser. However, I'm not sure how that would work with the MCE remote control. So I think I'll stick with what I've got. Time to move onto something else I guess... some other challenge for HMusicCentreXin.
Mitglieder in diesem Forum: 0 Mitglieder und 1 Gast
Du darfst keine neuen Themen in diesem Forum erstellen. Du darfst keine Antworten zu Themen in diesem Forum erstellen. Du darfst deine Beiträge in diesem Forum nicht ändern. Du darfst deine Beiträge in diesem Forum nicht löschen. Du darfst keine Dateianhänge in diesem Forum erstellen.