Cms_MMSJpeg.h
上传用户:tqh2500
上传日期:2014-05-09
资源大小:163k
文件大小:5k
开发平台:

Visual C++

  1. /**************************************************************************
  2. Copyright (c) 2001-2002 MobileSoft Corporation All Rights Reserved.
  3. Environment: Windows 2000 
  4. Created: 20:5:2003   8:48
  5. Filename:  CmsJpegLib.h
  6. Author: teng yong
  7. E_Mail: teng.yong@sohu.com/yongt@moiblesoft.com.cn
  8. Declare:
  9.     This document contains information proprietary to MobileSoft Technology
  10. (Nanjing),Corp. Transmittal, receipt, or possession of this document 
  11. does not express,license, or imply any rights to use, sell, design, or
  12. manufacture from this information. No reproduction, publication, or 
  13. disclosure of this information,in whole or in part, shall be made without
  14. prior written authorization from  an officer of MobileSoft Technology 
  15. (NanJing) Corp.
  16. Abstract: Jpeg api function
  17. Modify records: 
  18. Who           When Where       For What       Status
  19. TengYong   15:10     NanJing     Create         Finished 
  20. **************************************************************************/
  21. #ifndef CmsJpegLib_h_
  22. #define CmsJpegLib_h_
  23. typedef int (*jpegdrawproc)(unsigned char *, int,int,int,int,int,double);//callback used to jpeg draw 
  24. /********************************************************************
  25.  int GetJpegInfo(char *filename,int screenwidth,int *pwidth,int *pheight)
  26.  Description:  如果screenwidth == -1,得到实际的长度与高度;否则得到压缩
  27.                 后的长度与高度;
  28.  Param :  (IN)filename;   Jpeg文件名称:
  29.                  (IN)screenwidth;显示屏幕的宽度;
  30.                  (OUT)pwidth;    图片宽度;
  31.                  (OUT)pheight;   图片高度;
  32.  Return : 0; if OK;
  33. -1;if Error. pwidth == NULL || pheight == NULL 
  34.                 || screenwidth== 0 || filename == NULL;
  35.  Date : 2003-7-30
  36.  Author : 滕永; yongt@mobilesoft.com.cn
  37. *********************************************************************/
  38. int GetJpegInfo(char *filename,int screenwidth,int *pwidth,int *pheight);
  39. /***************************************************************************
  40.  int DrawJpeg(char *filename,void * pDrawPixel);
  41.  Description: 显示一幅JPEG画形文件.
  42.  Param : (IN)filename, 待显示的文件名称;
  43. (IN)pDrawPixel, 画一行JPEG数据的回调函数;
  44. (IN)xPosition, x方向原点坐标;
  45. (IN)yPosition, y方向原点坐标;
  46.  Return : 0; if OK;
  47. -1;if Error;
  48.  Date : 2003-6-9
  49.  Author : 滕永; yongt@mobilesoft.com.cn
  50. ****************************************************************************/
  51. int DrawJpeg(char *filename,jpegdrawproc pDrawPixel,int xPosition,int yPosition,int screenwidth); //  Modified by TIPrj[2005/7/20]
  52. #endif/**************************************************************************
  53. Copyright (c) 2001-2002 MobileSoft Corporation All Rights Reserved.
  54. Environment: Windows 2000 
  55. Created: 20:5:2003   8:48
  56. Filename:  CmsJpegLib.h
  57. Author: teng yong
  58. E_Mail: teng.yong@sohu.com/yongt@moiblesoft.com.cn
  59. Declare:
  60.     This document contains information proprietary to MobileSoft Technology
  61. (Nanjing),Corp. Transmittal, receipt, or possession of this document 
  62. does not express,license, or imply any rights to use, sell, design, or
  63. manufacture from this information. No reproduction, publication, or 
  64. disclosure of this information,in whole or in part, shall be made without
  65. prior written authorization from  an officer of MobileSoft Technology 
  66. (NanJing) Corp.
  67. Abstract: Jpeg api function
  68. Modify records: 
  69. Who           When Where       For What       Status
  70. TengYong   15:10     NanJing     Create         Finished 
  71. **************************************************************************/
  72. #ifndef CmsJpegLib_h_
  73. #define CmsJpegLib_h_
  74. typedef int (*jpegdrawproc)(unsigned char *, int,int,int,int,int,double);//callback used to jpeg draw 
  75. /********************************************************************
  76.  int GetJpegInfo(char *filename,int screenwidth,int *pwidth,int *pheight)
  77.  Description:  如果screenwidth == -1,得到实际的长度与高度;否则得到压缩
  78.                 后的长度与高度;
  79.  Param :  (IN)filename;   Jpeg文件名称:
  80.                  (IN)screenwidth;显示屏幕的宽度;
  81.                  (OUT)pwidth;    图片宽度;
  82.                  (OUT)pheight;   图片高度;
  83.  Return : 0; if OK;
  84. -1;if Error. pwidth == NULL || pheight == NULL 
  85.                 || screenwidth== 0 || filename == NULL;
  86.  Date : 2003-7-30
  87.  Author : 滕永; yongt@mobilesoft.com.cn
  88. *********************************************************************/
  89. int GetJpegInfo(char *filename,int screenwidth,int *pwidth,int *pheight);
  90. /***************************************************************************
  91.  int DrawJpeg(char *filename,void * pDrawPixel);
  92.  Description: 显示一幅JPEG画形文件.
  93.  Param : (IN)filename, 待显示的文件名称;
  94. (IN)pDrawPixel, 画一行JPEG数据的回调函数;
  95. (IN)xPosition, x方向原点坐标;
  96. (IN)yPosition, y方向原点坐标;
  97.  Return : 0; if OK;
  98. -1;if Error;
  99.  Date : 2003-6-9
  100.  Author : 滕永; yongt@mobilesoft.com.cn
  101. ****************************************************************************/
  102. int DrawJpeg(char *filename,jpegdrawproc pDrawPixel,int xPosition,int yPosition,int screenwidth,int screenheightint, int iBegH,int iEndH); 
  103. #endif