TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: All
from: Darin McBride
date: 1996-02-18 15:02:16
subject: VioGetBuf

I'm trying to get a few 'speedy' text interfaces down, and I figure the
best way is to create the logical buffer and write to it, then use
VioShowBuf.

However... the documentation on the Vio calls are rather, um, sparse, and
without examples.    (At least the MS Windows SDK had
examples...)  Anyway, I was wondering if anyone could just point me in a
proper direction.  To this end, I have two questions:

VioGetBuf() wants an LVBPtr - a PULONG it says.  It should point to the
logical video buffer - is this supposed to be MY memory?  Can I allocate it
via 'new' in C++, or do I need to call a Dos* API function to allocate it
(and de-allocate in the destructor, obviously).

Secondly, how would I go about USING this?  I can think of only two bytes
required - the ASCII character and the colour attribute.  What else would
there be for the other two bytes per cell?  The documentation I have either
doesn't say, or at least doesn't point to information on this... is the
first byte the character and second colour, as it is in DOS (if I remember
correctly)?

(Or is there a better way altogether, short of going to PM-based?)

Thanks...

--- Maximus/2 3.01
* Origin: Tanktalus' Tower BBS (PVT) (1:342/708)
SEEN-BY: 50/99 78/0 270/101 620/243 711/401 409 410 413 430 808 809 934 955
SEEN-BY: 712/407 515 517 628 713/888 800/1 7877/2809
@PATH: 342/708 5015 61 3615/50 396/1 270/101 712/515 711/808 809 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.