提问分类 [bug]

提问

1

价值

2

回答

374

浏览

EasyX似乎peekmessage的消息类型选择不太管用?

#include<iostream>
#include<easyx.h>
int main()
{
	initgraph(300, 300);
	ExMessage msg;
	while (1) {
		if (peekmessage(&msg, EX_KEY))
			std::cout << "gotted\n";
	}
} 

msg捕获到WM_MOUSEMOVE事件(调试可得),但是EX_KEY不应该捕获这类

bug
ava
xiaobbl

2024-2-13

1

价值

1

回答

716

浏览

发现 EasyX 20220901 的新 bug,关于未创建窗口时 SetWorkingImage(0) 的问题

问题描述

通常,在对某个 IMAGE 对象绘制时,我们会先保存旧的 WorkingImage,然后在 SetWorkingImage 到待绘制的 IMAGE 对象。

这样,我们就可以在对 IMAGE 对象绘制后,使用 SetWorkingImage 将绘制目标恢复到原先的状态。

这是很常见的做法。但是,如果在没有创建绘图窗口的情况下,上述操作就会出现问题。

触发 bug 的代码

#include <graphics.h>
ava
huidong

2023-1-15

5

价值

2

回答

5031

浏览

vs2017 64 位程序上编译出现 link2001 错误

最新版 EasyX_20200315(beta) 在 Win10 + VS2017 平台编译 64 位时, 会出现 link2001 错误, 而 x86 不会

程序:

#include <stdio.h>
#include <graphics.h>
#include <stdlib.h>
#include <math.h>
const int wid = 600, hei = 600;
const int Rrout = 200, 
bug
ava
核火箭

2020-3-23

技术讨论社区