Results 1 to 14 of 14

Thread: [c] Writing lines without any graphics.h

  1. #1

    Thread Starter
    Member
    Join Date
    May 2002
    Posts
    37

    [c] Writing lines without any graphics.h

    Hi
    I was trying to paint to my screen, but since I cannot use graphics.h (I am trying to write my own OS and graphics.h is os-based) I was searching for C code for this job. Does anybody know by example how to paint a line do the screen

  2. #2
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    If you're writing your own OS, look for the VBE documentation (google!)
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  3. #3

    Thread Starter
    Member
    Join Date
    May 2002
    Posts
    37
    Poznámka nad èarou: Tohle není angliètina. Ale kdyby to snad nìkdo
    ...Now I understand
    This is Google's 'best match' option for "VBE documentation". Sleep well, google. I SAID ENGLISH PAGES
    But now I've found it. Thank you very much.

    [edit] One more question. What do they mean with Microsoft C 6? I know Microsoft Visual C++ but I never heard from Microsoft C 6, and microsoft.com either not. [/edit]
    Last edited by DaNoVB; Jun 27th, 2002 at 03:00 AM.

  4. #4
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    Probably the old MS C for DOS
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  5. #5

    Thread Starter
    Member
    Join Date
    May 2002
    Posts
    37
    Does anybody know where I can download it? Even Microsoft.com is not providing even any information about Microsoft C.

  6. #6
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    An MS compiler won't help you if it's your own OS. You'll need to write your own compiler
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  7. #7

    Thread Starter
    Member
    Join Date
    May 2002
    Posts
    37
    Well, as it is a DOS compiler, it can do it's work, because it should be possible to compile plain binary files, and those are the ones I need for my OS (and every os, usually). All bootloaders, all kernels from an OS are in plain binary format. Now don't get saying "but windows has kernel32.dll", that file is just loaded by the REAL Windows kernel. Believe me (and no, I've got no access to the sources, but I just know that this way is the only way, because somebody needs to call that dll.)

  8. #8
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    The core parts of the OS (in NT at least) get loaded from the file ntldr on your root partition, this would in turn use kernel32.dll for all the scheduling, etc.

    So kernel32.dll is the main kernel, while ntldr gets everything into memory.


    Hmmm, perhaps, but you'd still need to reinvent a fair bit (you need to make sure it doesn't generate any DOS int 21h service calls.

    PS: You *will* need to learn assembly, the boot sector is only 512 bytes and you gotta get your OS loader squeezed into that...C is a bit too heavyweight for that I think
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  9. #9

    Thread Starter
    Member
    Join Date
    May 2002
    Posts
    37
    Who do you think I are?? Mr. Idiot or something?? I AM MAKING MY OWN OS, and before you can start working @ the GUI, you first need to do 'some' other things

  10. #10
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    Not at all. Just making sure you're aware of everything before you churn hours into it, get hopelessly lost, and give up in disgust and go back to bashing MS like the rest of us

    Aaaanyway. Did you find the VBE documentation?
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  11. #11

    Thread Starter
    Member
    Join Date
    May 2002
    Posts
    37
    Yes. I've found them. But I can't find the MS C 6 compiler for what the sources in it are meant I will try it with TCC.
    But it is very fine, that the sources in there are in PDF format, so if I want to try them, I'll need to typ everything again

  12. #12
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    Using Acrobat, you can pick the "Select" button on the toolbar to copy and paste them. You might need to do a little reformatting on them first, though

    As long as it's a DOS compiler you should be fine...although I'm sure MS wouldn't object to you "acquiring" a copy of the aforementioned MS C 6
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  13. #13
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    The nice thing about MS is that they don't give away their apps for free even when they're not even selling them anymore. So you actually have no other option of getting MSC6 than illegally, and that is hard too.
    But get a linux box and use gcc, it still can compile to plain binary.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  14. #14

    Thread Starter
    Member
    Join Date
    May 2002
    Posts
    37
    Nice?? d*mned ms c 6 I'll just use DJGPP...even contacted ms 'bout it

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