Results 1 to 3 of 3

Thread: Reading Video Ram

  1. #1

    Thread Starter
    New Member
    Join Date
    Mar 2002
    Location
    Washington DC
    Posts
    1

    Reading Video Ram

    I am a newbie and all you guys are quite advanced. This may be a dumb or trivial question. Is it possible to read the video ram using VB?. I need this capability to do some very simple object recognition by image capture using a camera and the video monitor. The picture is always frozen frame or static, and B/W mode is fine. Any thoughts or help out there would be appreciated.
    vbnewbie

  2. #2
    jim mcnamara
    Guest
    Low-level memory access is blocked on any of the NT OS machines.

    In the Win9X family, you can use RtlMoveMemory to directly read (like PEEK in ancient BASIC) memory if you know the address.

    for example, pretending that you wanted to read address &HFFAA

    Code:
    Private Declare Sub RtlMoveMemory Lib "kernel32.dll" (Destination As Any, Source As Any,ByRef Length As SIZE_T )
    
    Dim a as Byte
     Call RTLMoveMemory(a,&HFFAA,LenB(a) )
    ' a now has the value at that memory location

  3. #3
    Fanatic Member PsychoMark's Avatar
    Join Date
    Feb 2001
    Location
    Netherlands
    Posts
    540
    If you want to get an image from a camera, look around for "Video for Windows", I use those APIs with my webcam (trying to create my own motion detection at the moment). For still frames my cam also supports TWAIN, so you might want to take a look at that too....
    Teaudirenopossum.Musasapientumfixaestinaure.
    (I can't hear you. There's a banana in my ear)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width