QGraphicsPixmapItem: No such file or directory ^

294 Views Asked by At

I have a problem with Qt. I made some code yesterday and yesterday
everything worked fine, but today i got this message. I reinstalled Qt two times and still got same message on different projects. Someone know how to deal with this? Here is error that i got from compile output

C:/Qt/Tools/mingw492_32/bin/mingw32-make -f Makefile.Debug mingw32-make[1]: Entering directory 'C:/Users/michal/Documents/build-Game_2-Desktop_Qt_5_6_3_MinGW_32bit-Debug' g++ -pipe -fno-keep-inline-dllexport -g -std=gnu++0x -frtti -Wall -Wextra -fexceptions -mthreads -DUNICODE -DQT_DEPRECATED_WARNINGS -DQT_QML_DEBUG -DQT_WIDGETS_LIB -DQT_MULTIMEDIA_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_NEEDS_QMAIN ../Game_2/tower.cpp -o ../Game_2/Tower In file included from ../Game_2/tower.cpp:1:0: ../Game_2/tower.h:3:31: fatal error: QGraphicsPixmapItem: No such file or directory #include ^ compilation terminated. : recipe for target '../Game_2/Tower' failed mingw32-make[1]: Leaving directory 'C:/Users/michal/Documents/build-Game_2-Desktop_Qt_5_6_3_MinGW_32bit-Debug' makefile:34: recipe for target 'debug' failed mingw32-make[1]: * [../Game_2/Tower] Error 1 mingw32-make: * [debug] Error 2 18:46:16: The process "C:\Qt\Tools\mingw492_32\bin\mingw32-make.exe" exited with code 2. Error while building/deploying project Game_2 (kit: Desktop Qt 5.6.3 MinGW 32bit) When executing step "Make" 18:46:16: Elapsed time: 00:01.

and code:

#ifndef TOWER_H
#define TOWER_H
#include <QGraphicsPixmapItem>
#include <QGraphicsPolygonItem>
#include <QGraphicsItem>
class Tower: public QGraphicsPathItem
{
public:
    Tower(QGraphicsItem * parent = 0);
private:
    QGraphicsPolygonItem * attack_area;

};

#endif // TOWER_H

https://pastebin.com/u/NoName977

0

There are 0 best solutions below