QDataStream in(&file);
         int n;
         in >> n ;
         file.close();
         qDebug() << n<<"en" <<endl;

输出:1112355545 en 

 

           QByteArray s;
           in >> s;
           file.close();
           qDebug() <<s<<"en"<<endl;

输出:"" en 

 

 

【QT】二进制读取图像文件测试

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-02
  • 2021-12-07
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-04-08
  • 2021-12-13
  • 2022-01-25
相关资源
相似解决方案