[glutils] Add FrameBuffer::sizef
This commit is contained in:
		
							
								
								
									
										9
									
								
								deps/glutils/include/glutils/glutils.hpp
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										9
									
								
								deps/glutils/include/glutils/glutils.hpp
									
									
									
									
										vendored
									
									
								
							| @@ -13,6 +13,7 @@ | ||||
| #include <ox/std/error.hpp> | ||||
| #include <ox/std/size.hpp> | ||||
| #include <ox/std/string.hpp> | ||||
| #include <ox/std/vec.hpp> | ||||
| #include <ox/std/vector.hpp> | ||||
|  | ||||
| namespace glutils { | ||||
| @@ -138,6 +139,14 @@ struct FrameBuffer { | ||||
| 		return fbo.id; | ||||
| 	} | ||||
|  | ||||
| 	[[nodiscard]] | ||||
| 	constexpr ox::Vec2 sizef() const noexcept { | ||||
| 		return { | ||||
| 			static_cast<float>(width), | ||||
| 			static_cast<float>(height), | ||||
| 		}; | ||||
| 	} | ||||
|  | ||||
| 	[[nodiscard]] | ||||
| 	constexpr ox::Size size() const noexcept { | ||||
| 		return { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user