Solved

Scanning the framebuffer for changes

Posted on 2006-06-22
7
225 Views
Last Modified: 2010-08-05
Hey folks,

I'm developing a remote desktop app similar to VNC. I'm trying to scan the framebuffer for changes  but it takes a REALLY long time. I'm using methods similar to other VNC apps, with the difference that I can't go through X, but need look directly at the framebuffer.

I mmap the local framebuffer to a char* buffer, but for some reason comparing portions of it to what I have in my "check against" buffer take much longer than I expected.

What I mean is, using memcmp to compare two data buffers I've created takes almost no time, whereas comparing a data buffer I've created to a portion of the mmap'ed framebuffer takes many times longer.

Are there VNC or VNC-like apps out there that don't go through X, and are they any good?

Do I need to go even lower, to the drivers?

Many many thanks for your help.
0
Comment
Question by:quadrille01
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
7 Comments
 
LVL 8

Expert Comment

by:manish_regmi
ID: 17057502
what about using DirectFb library.

http://www.directfb.org/

regards
Manish Regmi
0
 

Author Comment

by:quadrille01
ID: 17058453
I looked at DirectFB but from what I can tell its accellerated for write but not read. From some other reading I've learned that most video cards don't provide much bandwidth for reading. I mean at the hardware level. I'm looking at Xvfb right now. That keeps the framebuffer in system memory.

Nathan
0
 
LVL 8

Accepted Solution

by:
manish_regmi earned 250 total points
ID: 17060672
There is another library which directly access hardware. Its called svgalib (www.svgalib.org). It is used in application where X cannot perform well like video games. Doom and Quake are already ported to that library.
You can give it a try.

regards
Manish Regmi
 
0
 
LVL 34

Assisted Solution

by:Duncan Roe
Duncan Roe earned 250 total points
ID: 17063137
We used svgalib in a project at work: were never able to read the sceen back at all. We wanted screen shots for the user manual but had to resort to Windows screenscraper while running it under VMWare. So it may not suit your needs.
Must say I did find the framebuffer X driver to be very slow when I tried it, compared to one that drove the chip directly. So it would seem there might be something inherently slow in the implementation. If so, could it be improved?
That would need someone (you?) to look with fresh eyes at how Linux is doing it now. Wish I could help you more, best of luck anyway
0
 

Author Comment

by:quadrille01
ID: 17063480
Overall video performance(by which I mean frames-per-second) is less of an issue right now than the CPU cycles that framebuffer scanning eats up.I wonder if there's a scanning algorithm thats been tested as mathematically the most efficient or something.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

710 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question