是否可以在html5中使用C ++代码? [英] Is it possible to use C++ code in html5?

查看:79
本文介绍了是否可以在html5中使用C ++代码?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想制作一个应用程序,为此我需要包括我的c ++代码的一部分以进行计算.对于GUI,我正在使用HTML5.那么有可能在HTML5中包含C ++代码吗?

I want to make an app for which i need to include a part of my c++ code for calculation. For GUI i'm using HTML5. So is it possible to include C++ code into HTML5 ?

推荐答案

否.你不能那样做.尝试将C ++移植到JavaScript.您可以看看项目,该项目声称它可以将C ++代码转换为JavaScript.我从来没有尝试过这个.

No. You can't do that. Try porting your C++ to JavaScript. You could take a look at this project that claims it can convert C++ code to JavaScript. I have never tried this myself.

否则,您可以编写CGI来使用C ++程序,并使用AJAX来远程执行".

Otherwise, you could write a CGI to use your C++ program and use AJAX to "remote execute it".

这篇关于是否可以在html5中使用C ++代码?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆