如何获取JPEG文件的大小以进行读取? [英] How to get the size of the JPEG file in order to read it?

查看:167
本文介绍了如何获取JPEG文件的大小以进行读取?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何获取JPEG文件的大小以将其读取为二进制文件?

How to get the size of the JPEG file in order to read it as binary?

推荐答案

jpeg文件的大小仅是文件的大小,使用可用于查找文件大小的任何内容,例如:
http://msdn.microsoft.com/en-us/library/aa364955%28v = vs.85%29.aspx [ ^ ]
Size of a jpeg file is just the size of the file, use anything that can be used to find file size, such as:
http://msdn.microsoft.com/en-us/library/aa364955%28v=vs.85%29.aspx[^]


使用CreateFile()打开文件

使用GetFileSize()获取文件大小
然后使用ReadFile()
读取文件
完成后,使用CloseHandle()关闭文件;

在Google上搜索功能,以便您可以学习参数. :)
Open the file using CreateFile()

get the file size with GetFileSize()

and then Read the file using ReadFile()

once finished close the file using CloseHandle();

search for the functions on Google so you can learn the parameters. :)


这篇关于如何获取JPEG文件的大小以进行读取?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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