Compare commits
2 Commits
f4ba9b3df3
...
f01d539489
| Author | SHA1 | Date | |
|---|---|---|---|
| f01d539489 | |||
| 8fffe4d8e3 |
@@ -12,3 +12,4 @@ set (CMAKE_CXX_STANDARD 20)
|
|||||||
add_executable(one main.cpp)
|
add_executable(one main.cpp)
|
||||||
|
|
||||||
target_link_libraries(one m Qt6::Widgets Qt6::Gui)
|
target_link_libraries(one m Qt6::Widgets Qt6::Gui)
|
||||||
|
# target_link_libraries(one m)
|
||||||
|
|||||||
2
main.cpp
2
main.cpp
@@ -89,7 +89,6 @@ int main(int argc, char *argv[]) {
|
|||||||
begin)
|
begin)
|
||||||
.count()
|
.count()
|
||||||
<< "[ms]" << std::endl;
|
<< "[ms]" << std::endl;
|
||||||
QApplication a(argc, argv);
|
|
||||||
|
|
||||||
uint8_t *pixel = new uint8_t[64 * 64 * 3];
|
uint8_t *pixel = new uint8_t[64 * 64 * 3];
|
||||||
/*for (int i = 0; i < 64 * 64 * 3; i++) {
|
/*for (int i = 0; i < 64 * 64 * 3; i++) {
|
||||||
@@ -115,6 +114,7 @@ int main(int argc, char *argv[]) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
QApplication a(argc, argv);
|
||||||
QWidget widget;
|
QWidget widget;
|
||||||
widget.setAutoFillBackground(true);
|
widget.setAutoFillBackground(true);
|
||||||
widget.setGeometry(0, 0, 500, 500);
|
widget.setGeometry(0, 0, 500, 500);
|
||||||
|
|||||||
@@ -85,12 +85,11 @@ class Renderer {
|
|||||||
for (int x = startX; x < endX; x++) {
|
for (int x = startX; x < endX; x++) {
|
||||||
for (int y = startY; y < endY; y++) {
|
for (int y = startY; y < endY; y++) {
|
||||||
|
|
||||||
testP.calcBarycentric(pos);
|
if (testP.depContains(pos)) {
|
||||||
|
|
||||||
if (testP.contains(pos)) {
|
|
||||||
if (testP.small)
|
if (testP.small)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
testP.calcBarycentric(pos);
|
||||||
decimal depth = testP.calcDepth();
|
decimal depth = testP.calcDepth();
|
||||||
if (depth < target->getDepth(x, y)) {
|
if (depth < target->getDepth(x, y)) {
|
||||||
// std::cout << factors << std::endl;
|
// std::cout << factors << std::endl;
|
||||||
|
|||||||
Reference in New Issue
Block a user