jacklicn / leptonica

Automatically exported from code.google.com/p/leptonica
0 stars 0 forks source link

Compile Error #75

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
1>------ 已启动生成: 项目: liblept168, 配置: LIB Debug Win32 ------
1>  rotate.c
1>..\src\rotate.c(382): warning C4013: 
“GET_DATA_FOUR_BYTES”未定义;假设外部返回 int
1>..\src\rotate.c(383): warning C4013: 
“SET_DATA_FOUR_BYTES”未定义;假设外部返回 int
1>..\src\rotate.c(386): error C2036: “void *”: 未知的大小
1>..\src\rotate.c(386): error C2100: 非法的间接寻址
1>..\src\rotate.c(386): error C2296: “>>”: 
非法,左操作数包含“void *”类型
1>..\src\rotate.c(390): error C2036: “void *”: 未知的大小
1>..\src\rotate.c(390): error C2100: 非法的间接寻址
1>..\src\rotate.c(390): error C2296: “>>”: 
非法,左操作数包含“void *”类型
========== 生成: 成功 0 个,失败 1 个,最新 0 个,跳过 0 个 
==========

[1] 'GET_DATA_FOUR_BYTES' define and 'SET_DATA_FOUR_BYTES' define?
[2]
#define  GET_DATA_BIT(pdata, n) \
    ((*((pdata) + ((n) >> 5)) >> (31 - ((n) & 31))) & 1)

#define  GET_DATA_BIT_CHANGED(pdata, n) \
    ((*((unsigned char *)(pdata) + ((n) >> 5)) >> (31 - ((n) & 31))) & 1)

GET_DATA_BIT under vs2010 will got error C2296,C2036,C2100.

Original issue reported on code.google.com by rlib2014@gmail.com on 29 Jan 2013 at 4:58

GoogleCodeExporter commented 9 years ago
#define  GET_DATA_BIT_CHANGED_2(pdata, n) \
    ((*((l_uint32 *)(pdata) + ((n) >> 5)) >> (31 - ((n) & 31))) & 1)

I don't know which is correct.

Original comment by rlib2014@gmail.com on 29 Jan 2013 at 5:12

GoogleCodeExporter commented 9 years ago
[3]
warning C4700: 使用了未初始化的局部变量“offset” 
\leptonica\src\pixcomp.c line:1466

Original comment by rlib2014@gmail.com on 29 Jan 2013 at 5:17

GoogleCodeExporter commented 9 years ago
I don't understand your problem.  The image data ptr must be cast to an 
unsigned 32 bit int, as in arrayaccess.h.  Why are you using these other macros?

Original comment by dan.bloo...@gmail.com on 29 Jan 2013 at 5:34

GoogleCodeExporter commented 9 years ago
thanks, this problem have been solved.

Original comment by rlib2014@gmail.com on 29 Jan 2013 at 11:57

GoogleCodeExporter commented 9 years ago

Original comment by dan.bloo...@gmail.com on 30 Jan 2013 at 12:26