This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| FROM ubuntu:latest as tizen | |
| RUN apt-get update | |
| RUN apt-get install wget -y | |
| RUN wget https://download.tizen.org/sdk/Installer/tizen-studio_5.1/web-cli_Tizen_Studio_5.1_ubuntu-64.bin | |
| RUN chmod u+x web-cli_Tizen_Studio_5.1_ubuntu-64.bin | |
| RUN chown 1000:1000 web-cli_Tizen_Studio_5.1_ubuntu-64.bin | |
| RUN useradd -ms /bin/bash tizen | |
| USER tizen | |
| RUN /bin/bash -c 'echo y |./web-cli_Tizen_Studio_5.1_ubuntu-64.bin --accept-license' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <vector> | |
| #include <iostream> | |
| using block_type = unsigned char; | |
| using block_container = std::vector<block_type>; | |
| using block_iterator = block_container::const_iterator; | |
| // Get the counter and top-most bits | |
| // (1111 1111) / 2 = (0111 1111) integer division always rounds down | |
| static const block_type counter_bits = | |
| std::numeric_limits<block_type>::max() / 2; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| namespace detail | |
| { | |
| template<typename ...> | |
| struct concat; | |
| template<template<typename ...> typename T, typename ...Args, typename ...Ts> | |
| struct concat<T<Args...>, Ts...> | |
| { | |
| // This function just generates an index_sequence over Args and forwards | |
| // it to the other construct function within this structure |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <vector> | |
| template<typename Image, typename PixelType = typename Image::pixel_type> | |
| struct view | |
| { | |
| view(Image &img, | |
| unsigned int x, | |
| unsigned int y, | |
| unsigned int width, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int main() | |
| { | |
| // Ranged-based iteration | |
| for(auto i : static_interval<0, 10, 2>()) | |
| std::cout << i << " "; | |
| std::cout << std::endl; | |
| // Reverse manual iteration | |
| auto m = static_interval<1, 10>(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| template<typename storage> | |
| void vec3_test() | |
| { | |
| // Standard constructor | |
| vector<3, storage> control(1, 2, 3); | |
| assert(control.x == 1); | |
| assert(control.y == 2); | |
| assert(control.z == 3); | |
| // Construct from initialization list |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <Windows.h> | |
| #include <exception> | |
| #include <Dbghelp.h> | |
| #include <iostream> | |
| #include <Psapi.h> | |
| #include <string> | |
| #include <vector> | |
| #pragma comment(lib, "Dbghelp.lib") |