装配视频模式坐标映射到字符坐标
我正在开发一个 8086 dos 汇编项目,使用视频模式我能够绘制一些线条和东西,但现在我想打印一些字符并发现 (中断 10,2) 使用与视频模式坐标不同的字符(行、列)
坐标在这两个坐标之间映射的优雅方式? 或者有更好的方法在视频模式下打印字符?
我目前所知道的是,我可以手动进行映射,但它不会准确,因为 8086 中没有浮点运算...
I am working on an 8086 dos assembly project , using video mode i was able to draw some lines and stuff but now i want to print some characters and found that (interrupt 10,2) uses character (row,col) coordinates that is different than video mode coordinates
what is the most elegant way to map between those two coordinates ?
or there is a better way to print characters in video mode ?
what i know currently is that i can do the mapping manually but it won't be accurate as there is no floating point operations in 8086...
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
由于不允许使用外部库,我最终做了一个简单的七段,例如绘制数字的程序,它看起来像这样
代码可以在 这里如果有人感兴趣
Since it wasn't allowed to use external libraries , i ended up doing a simple seven segment like procedure do draw numbers , it looks something like this
the code can be found here if any one is interested
在这里您会发现一个出色的 ASM 库,例如实现:
GPRINT 在图形屏幕上打印 ASCIIZ 字符串
HTH!
Here you'll find an outstanding ASM library implementing for example:
GPRINT prints ASCIIZ string on a graphics screen
HTH!
您需要的所有内容都应在以下书中:
http://www.amazon.com/gp/offer-listing/091539135X/ref=dp_olp_0?ie=UTF8&redirect=true&condition=all
不幸的是,随着时间的推移/这项技术有多古老了,所有这些书籍都越来越难找到,过去在互联网上流传的所有信息似乎也逐渐从离线状态下消失。
Everything you need should be in the following book:
http://www.amazon.com/gp/offer-listing/091539135X/ref=dp_olp_0?ie=UTF8&redirect=true&condition=all
Unfortunately, with the advancement of time/how old that technology is and all, those books are getting harder to find and all the info that used to be floating around on the Internet seems to gradually dropping offline too.