Added Read method
This commit is contained in:
@@ -4,6 +4,7 @@ project(BmpPP_exec)
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
|
||||
ADD_COMPILE_DEFINITIONS(_EULE_NO_INTRINSICS_)
|
||||
ADD_COMPILE_DEFINITIONS(_BMPLIB_DEBUG_OUTPUT_)
|
||||
|
||||
INCLUDE_DIRECTORIES(../Src/Eule/)
|
||||
INCLUDE_DIRECTORIES(../Src/)
|
||||
|
@@ -6,6 +6,7 @@ using namespace Leonetienne::BmpPP;
|
||||
|
||||
int main() {
|
||||
|
||||
/*
|
||||
BMP bmp({800, 600}, Colormode::RGB);
|
||||
|
||||
for (int x = 0; x < 800; x++)
|
||||
@@ -19,8 +20,19 @@ int main() {
|
||||
);
|
||||
}
|
||||
|
||||
if (!bmp.Write("test.bmp"))
|
||||
std::cerr << "What the hell" << std::endl;
|
||||
*/
|
||||
|
||||
BMP bmp;
|
||||
|
||||
if (!bmp.Read("test.bmp"))
|
||||
std::cerr << "Failed to read" << std::endl;
|
||||
|
||||
std::cout << (bmp.GetColormode() == Colormode::RGB) << std::endl;
|
||||
|
||||
if (!bmp.Write("testwrite.bmp"))
|
||||
std::cerr << "What the hell" << std::endl;
|
||||
|
||||
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user