Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


speeding up reading from vram


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
3 replies to this topic

#1 Staffan   Members   -  Reputation: 122

Like
Likes
Like

Posted 22 January 2000 - 06:33 AM

we all know reading from the video ram is a real pain, now the question is; are there any neat ways to speed it up? memcpy each line into system memory and then process each pixel from there? if there are any better ways to do it then reading pixel per pixel from vram, not that i think there are, please drop me a note. thanks in advance Edited by - Staffan on 1/22/00 12:35:31 PM

Sponsor:

#2 Facehat   Members   -  Reputation: 696

Like
Likes
Like

Posted 22 January 2000 - 12:19 PM

Well, I don''t think there is anything like your describing. One idea though: say you want to read a block off the screen. What you might try doing is creating an offscreen *sytem* memory surface. Then use Blt to copy the area of the backbuffer you want to read to the offscreen surface. You can then read/modify the stuff in the offscreen surface, and reupload it when you want to. It''s probably much faster then reading each pixel from the backbuffer since:

1) some cards can do Vid->Sys blts really quickly (there accelerated)
2) your not requesting it one at a time, but instead getting it in one big block

I haven''t tried this myself (never needed to read from vidmem), but I think it might work. Tell me what you think .

--TheGoop

#3 Staffan   Members   -  Reputation: 122

Like
Likes
Like

Posted 23 January 2000 - 06:27 AM

thanks alot! ill try implenting it, right away actually! ill post the results of it later.

#4 Staffan   Members   -  Reputation: 122

Like
Likes
Like

Posted 23 January 2000 - 07:11 AM

Well, damn, it didnt improve my previous results. The technique you described, blitting the backbuffer to an offscreen surface, read for it and update it and blt it back on to the backbuffer actually slowed it down my 2 fps. Though, just using it for reading and writing to the backbuffer manually kept it at the same speed as my original routine. Guess my assembly routines are just to damn fast to be any more optimized They''re reasonble fast so i guess ill keep them the way they are, though its become some of an obsession to see how far i can push it




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS