Added tutorials "06 - Descriptor Sets" and "07 - Uniform Buffers". Added functions for projection matrices generation to Tools. Added function for loading images from files (with stb_image library). Updated README.md file with description of Tutorial06.

This commit is contained in:
plapins
2016-06-22 23:23:22 +02:00
parent 37d04f3be5
commit c064ec5a4a
26 changed files with 10307 additions and 6 deletions

View File

@@ -13,6 +13,7 @@
#include <string>
#include <vector>
#include <array>
#include "vulkan.h"
namespace ApiWithoutSecrets {
@@ -83,6 +84,27 @@ namespace ApiWithoutSecrets {
// ************************************************************ //
std::vector<char> GetBinaryFileContents( std::string const &filename );
// ************************************************************ //
// GetImageData //
// //
// Function loading image (texture) data from a specified file //
// ************************************************************ //
std::vector<char> GetImageData( std::string const &filename, int requested_components, int *width, int *height, int *components, int *data_size );
// ************************************************************ //
// GetPerspectiveProjectionMatrix //
// //
// Function calculating perspective projection matrix //
// ************************************************************ //
std::array<float, 16> GetPerspectiveProjectionMatrix( float const aspect_ratio, float const field_of_view, float const near_clip, float const far_clip );
// ************************************************************ //
// GetOrthographicsProjectionMatrix //
// //
// Function calculating orthographic projection matrix //
// ************************************************************ //
std::array<float, 16> GetOrthographicProjectionMatrix( float const left_plane, float const right_plane, float const top_plane, float const bottom_plane, float const near_plane, float const far_plane );
} // namespace Tools
} // namespace ApiWithoutSecrets