Thread: About poking in memory to see chars on the screen

  1. #1
    Registered User
    Join Date
    Nov 2001
    Location
    Mexico City
    Posts
    33

    About poking in memory to see chars on the screen

    Hi.

    I'm wondering if you can modify values in memory locations that correspond to the screen.
    I used to do this before, but now it doesn't work.
    I'm trying to make a program that scrolls text on the screen, so I want a procedure that works fast. Printf(), or puts(), is too slow.

    I will appreciatte any response, thanks. (good nigth!)

    Gustaff.
    If you want to be happy one hour: take a nap
    if you want to be happy one day: go fishing
    If you want to be happy a year: inherit a fortune
    if you want to be happy for a life time: HELP SOMEBODY
    chinisse say.

  2. #2
    Guest Sebastiani's Avatar
    Join Date
    Aug 2001
    Location
    Waterloo, Texas
    Posts
    5,708
    Depends on your OS. I don't think a protected mode operating system will allow you to do it. At any rate, the address would be (according to this reference book anyway)0xb8000000L, and each byte of text would be followed by a text-attribute byte (usually set to 0x07).
    Code:
    #include <cmath>
    #include <complex>
    bool euler_flip(bool value)
    {
        return std::pow
        (
            std::complex<float>(std::exp(1.0)), 
            std::complex<float>(0, 1) 
            * std::complex<float>(std::atan(1.0)
            *(1 << (value + 2)))
        ).real() < 0;
    }

  3. #3
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,981

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 7
    Last Post: 02-06-2009, 12:27 PM
  2. Memory allocation/reallocation
    By magda3227 in forum C Programming
    Replies: 10
    Last Post: 07-04-2008, 03:27 PM
  3. To find the memory leaks without using any tools
    By asadullah in forum C Programming
    Replies: 2
    Last Post: 05-12-2008, 07:54 AM
  4. Feedback: Functional Specification Wording
    By Ragsdale85 in forum C++ Programming
    Replies: 0
    Last Post: 01-18-2006, 04:56 PM
  5. How To Make: Screen Killer (Game)
    By BillBoeBaggins in forum C++ Programming
    Replies: 3
    Last Post: 11-20-2003, 06:06 PM