{"action":"created","comment":{"url":"https://api.github.com/repos/mosra/magnum-plugins/pulls/comments/36648152","id":36648152,"diff_hunk":"@@ -0,0 +1,387 @@\n+/*\n+    This file is part of Magnum.\n+\n+    Copyright © 2010, 2011, 2012, 2013, 2014, 2015\n+              Vladimír Vondruš <mosra@centrum.cz>\n+    Copyright © 2015 Jonathan Hale <squareys@googlemail.com>\n+\n+    Permission is hereby granted, free of charge, to any person obtaining a\n+    copy of this software and associated documentation files (the \"Software\"),\n+    to deal in the Software without restriction, including without limitation\n+    the rights to use, copy, modify, merge, publish, distribute, sublicense,\n+    and/or sell copies of the Software, and to permit persons to whom the\n+    Software is furnished to do so, subject to the following conditions:\n+\n+    The above copyright notice and this permission notice shall be included\n+    in all copies or substantial portions of the Software.\n+\n+    THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL\n+    THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n+    FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER\n+    DEALINGS IN THE SOFTWARE.\n+*/\n+\n+#include <algorithm>\n+#include <cstring>\n+#include <fstream>\n+#include <sstream>\n+#include <Corrade/Containers/ArrayView.h>\n+#include <Corrade/Utility/Debug.h>\n+#include <Magnum/ColorFormat.h>\n+#include <Magnum/Trade/ImageData.h>\n+#include <MagnumPlugins/DdsImporter/DdsImporter.h>\n+#include <Magnum/Math/Functions.h>\n+#include <Magnum/Math/Vector3.h>\n+#include <Magnum/Math/Vector4.h>\n+\n+#ifdef MAGNUM_TARGET_GLES2\n+#include <Magnum/Context.h>\n+#include <Magnum/Extensions.h>\n+#endif\n+\n+namespace Magnum { namespace Trade {\n+\n+/**\n+ * Flags to indicate which members of a DdsHeader contain valid data.\n+ */\n+enum DdsDescriptionFlag: UnsignedInt {\n+    Caps = 0x00000001,       //!< Caps\n+    Height = 0x00000002,     //!< Height\n+    Width = 0x00000004,      //!< Width\n+    Pitch = 0x00000008,      //!< Pitch\n+    PixelFormat = 0x00001000,//!< PixelFormat\n+    MipMapCount = 0x00020000,//!< MipMapCount\n+    LinearSize = 0x00080000, //!< LinearSize\n+    Depth = 0x00800000       //!< Depth\n+};\n+\n+/**\n+ * Direct Draw Surface pixel format.\n+ */\n+enum DdsPixelFormat: UnsignedInt {\n+    AlphaPixels = 0x00000001,//!< AlphaPixels\n+    FourCC = 0x00000004,     //!< FourCC\n+    RGB = 0x00000040,        //!< RGB\n+    RGBA = 0x00000041        //!< RGBA\n+};\n+\n+/**\n+ * Specifies the complexity of the surfaces stored.\n+ */\n+enum DdsCaps1: UnsignedInt {\n+    /**\n+     * Set for files that contain more than one surface (a mipmap, a cubic environment map,\n+     * or mipmapped volume texture).\n+     */\n+    Complex = 0x00000008,\n+    Texture = 0x00001000,//!< Texture (required).\n+    MipMap = 0x00400000  //!< Is set for mipmaps.\n+};\n+\n+/**\n+ * Additional detail about the surfaces stored.\n+ */\n+enum DdsCaps2: UnsignedInt {\n+    Cubemap = 0x00000200,         //!< Cubemap\n+    CubemapPositiveX = 0x00000400,//!< CubemapPositiveX\n+    CubemapNegativeX = 0x00000800,//!< CubemapNegativeX\n+    CubemapPositiveY = 0x00001000,//!< CubemapPositiveY\n+    CubemapNegativeY = 0x00002000,//!< CubemapNegativeY\n+    CubemapPositiveZ = 0x00004000,//!< CubemapPositiveZ\n+    CubemapNegativeZ = 0x00008000,//!< CubemapNegativeZ\n+    CubemapAllFaces = 0x0000FC00, //!< CubemapAllFaces\n+    Volume = 0x00200000           //!< Volume\n+};\n+\n+/**\n+ * Compressed texture types.\n+ */\n+enum DdsCompressionTypes: UnsignedInt {\n+    DXT1 = 0x31545844, //!< (MAKEFOURCC('D','X','T','1')).\n+    DXT2 = 0x32545844, //!< (MAKEFOURCC('D','X','T','2')), not supported.\n+    DXT3 = 0x33545844, //!< (MAKEFOURCC('D','X','T','3')).\n+    DXT4 = 0x34545844, //!< (MAKEFOURCC('D','X','T','4')), not supported.\n+    DXT5 = 0x35545844, //!< (MAKEFOURCC('D','X','T','5')).\n+    DXT10 = 0x30315844 //!< (MAKEFOURCC('D','X','1','0')), not supported.\n+};\n+\n+inline std::string fourcc(UnsignedInt enc) {\n+    char c[5] = { '\\0' };\n+    c[0] = enc >> 0 & 0xFF;\n+    c[1] = enc >> 8 & 0xFF;\n+    c[2] = enc >> 16 & 0xFF;\n+    c[3] = enc >> 24 & 0xFF;\n+    return c;\n+}\n+\n+inline void convertBGRToRGB(char* data, const unsigned int size) {\n+    auto pixels = reinterpret_cast<Math::Vector3<UnsignedByte>*>(data);\n+    std::transform(pixels, pixels + size, pixels,\n+        [](Math::Vector3<UnsignedByte> pixel) { return Math::swizzle<'b', 'g', 'r'>(pixel); });\n+}\n+\n+inline void convertBGRAToRGBA(char* data, const unsigned int size) {\n+    auto pixels = reinterpret_cast<Math::Vector4<UnsignedByte>*>(data);\n+    std::transform(pixels, pixels + size, pixels,\n+        [](Math::Vector4<UnsignedByte> pixel) { return Math::swizzle<'b', 'g', 'r', 'a'>(pixel); });\n+}\n+\n+/**\n+ * Dds file header struct.\n+ */\n+struct DdsHeader {\n+    UnsignedInt     size;\n+    UnsignedInt     flags;\n+    UnsignedInt     height;\n+    UnsignedInt     width;\n+    UnsignedInt     pitchOrLinearSize;\n+    UnsignedInt     depth;\n+    UnsignedInt     mipMapCount;\n+    UnsignedInt     reserved1[11];\n+    struct {\n+        /* pixel format */\n+        UnsignedInt size;\n+        UnsignedInt flags;\n+        UnsignedInt fourCC;\n+        UnsignedInt rgbBitCount;\n+        UnsignedInt rBitMask;\n+        UnsignedInt gBitMask;\n+        UnsignedInt bBitMask;\n+        UnsignedInt aBitMask;\n+    } ddspf;\n+    UnsignedInt     caps;\n+    UnsignedInt     caps2;\n+    UnsignedInt     caps3;\n+    UnsignedInt     caps4;\n+    UnsignedInt     reserved2;\n+};\n+\n+DdsImporter::DdsImporter():\n+    _in(nullptr),\n+    _imageData2D(),\n+    _imageData3D()\n+{\n+\n+}\n+\n+DdsImporter::DdsImporter(PluginManager::AbstractManager& manager, std::string plugin):\n+    AbstractImporter(manager, std::move(plugin)),\n+    _in(nullptr),\n+    _imageData2D(),\n+    _imageData3D()\n+{\n+\n+}\n+\n+DdsImporter::~DdsImporter() { close(); }\n+\n+auto DdsImporter::doFeatures() const -> Features { return Feature::OpenData; }\n+\n+bool DdsImporter::doIsOpened() const { return _in; }\n+\n+void DdsImporter::doClose() {\n+    delete _in;\n+    _in = nullptr;\n+}\n+\n+void DdsImporter::doOpenData(const Containers::ArrayView<const char> data) {\n+    /* clear previous data */\n+    _imageData2D.clear();\n+    _imageData3D.clear();\n+\n+    _in = new std::istringstream{{data, data.size()}};\n+\n+    /* read magic number to verify this is a dds file. */\n+    char magic[4];\n+    _in->read(magic, 4);\n+    if (strncmp(magic, \"DDS \", 4) != 0) {\n+        Error() << \"Not a DDS file.\";\n+    }\n+\n+    /* read in DDS header */\n+    DdsHeader ddsh;\n+    _in->read(reinterpret_cast<char*>(&ddsh), sizeof(DdsHeader));\n+\n+    /* check if image is a 2D or 3D texture */\n+    const UnsignedByte dimensions = ((ddsh.caps2 & DdsCaps2::Volume) && (ddsh.depth > 0)) ? 3 : 2;\n+\n+    /* check if image is a cubemap */\n+    const bool isCubemap = (ddsh.caps2 & DdsCaps2::Cubemap);\n+\n+    bool compressed = false;\n+    union {\n+        ColorFormat uncompressed;\n+        CompressedColorFormat compressed;\n+    } colorFormat;\n+\n+    /* components per pixel */\n+    UnsignedInt components = 4;\n+\n+    /* set the color format */\n+    if (ddsh.ddspf.flags & DdsPixelFormat::FourCC) {\n+        switch (DdsCompressionTypes(ddsh.ddspf.fourCC)) {\n+            case DdsCompressionTypes::DXT1:\n+                colorFormat.compressed = CompressedColorFormat::RGBAS3tcDxt1;\n+                break;\n+            case DdsCompressionTypes::DXT3:\n+                colorFormat.compressed = CompressedColorFormat::RGBAS3tcDxt3;\n+                break;\n+            case DdsCompressionTypes::DXT5:\n+                colorFormat.compressed = CompressedColorFormat::RGBAS3tcDxt5;\n+                break;\n+            default:\n+                Error() << \"unknown texture compression '\" + fourcc(ddsh.ddspf.fourCC) + \"'\";\n+        }\n+        compressed = true;\n+    } else if (ddsh.ddspf.rgbBitCount == 32 &&\n+               ddsh.ddspf.rBitMask == 0x00FF0000 &&\n+               ddsh.ddspf.gBitMask == 0x0000FF00 &&\n+               ddsh.ddspf.bBitMask == 0x000000FF &&\n+               ddsh.ddspf.aBitMask == 0xFF000000) {\n+        colorFormat.uncompressed = ColorFormat::BGRA;\n+    } else if (ddsh.ddspf.rgbBitCount == 32 &&\n+               ddsh.ddspf.rBitMask == 0x000000FF &&\n+               ddsh.ddspf.gBitMask == 0x0000FF00 &&\n+               ddsh.ddspf.bBitMask == 0x00FF0000 &&\n+               ddsh.ddspf.aBitMask == 0xFF000000) {\n+        colorFormat.uncompressed = ColorFormat::RGBA;\n+    } else if (ddsh.ddspf.rgbBitCount == 24 &&\n+               ddsh.ddspf.rBitMask == 0x000000FF &&\n+               ddsh.ddspf.gBitMask == 0x0000FF00 &&\n+               ddsh.ddspf.bBitMask == 0x00FF0000) {\n+        colorFormat.uncompressed = ColorFormat::RGB;\n+        components = 3;\n+    } else if (ddsh.ddspf.rgbBitCount == 24 &&\n+               ddsh.ddspf.rBitMask == 0x00FF0000 &&\n+               ddsh.ddspf.gBitMask == 0x0000FF00 &&\n+               ddsh.ddspf.bBitMask == 0x000000FF) {\n+        colorFormat.uncompressed = ColorFormat::BGR;\n+        components = 3;\n+    } else if (ddsh.ddspf.rgbBitCount == 8) {\n+#ifndef MAGNUM_TARGET_GLES2\n+        colorFormat.uncompressed = ColorFormat::Red;\n+#else\n+        colorFormat.uncompressed = ColorFormat::Luminance;\n+#endif\n+    } else {\n+        Error() << \"Unknow texture format\";\n+    }\n+\n+    const UnsignedInt width = ddsh.width;\n+    const UnsignedInt height = ddsh.height;\n+    const UnsignedInt depth = Math::max(ddsh.depth, 1u);   // set to 1 if 0\n+\n+    /* check how many mipmaps to load */\n+    const UnsignedInt numMipmaps = (ddsh.flags & DdsDescriptionFlag::MipMapCount)\n+                    ? ((ddsh.mipMapCount == 0) ? 0 : ddsh.mipMapCount - 1)\n+                    : 0;\n+\n+    /* load all surfaces for the image (6 surfaces for cubemaps) */\n+    const UnsignedInt numImages = (isCubemap) ? 6 : 1;\n+    for (UnsignedInt n = 0; n < numImages; ++n) {\n+        if (compressed) {\n+            loadCompressedImageData(colorFormat.compressed, width, height, depth, dimensions);\n+        } else {\n+            loadUncompressedImageData(colorFormat.uncompressed, width, height, depth, components, dimensions);\n+        }\n+\n+        UnsignedInt w = width;\n+        UnsignedInt h = height;\n+        UnsignedInt d = depth;\n+\n+        /* load all mipmaps for current surface */\n+        for (UnsignedInt i = 0; i < numMipmaps && (w || h); i++) {\n+            /* shrink to next power of 2 */\n+            w = Math::max(w >> 1, 1u);\n+            h = Math::max(h >> 1, 1u);\n+            d = Math::max(d >> 1, 1u);\n+\n+            if (compressed) {\n+                loadCompressedImageData(colorFormat.compressed, w, h, d, dimensions);\n+            } else {\n+                loadUncompressedImageData(colorFormat.uncompressed, w, h, d, components, dimensions);\n+            }\n+        }\n+    }\n+\n+}\n+\n+void DdsImporter::loadUncompressedImageData(const ColorFormat format,\n+    const UnsignedInt width, const UnsignedInt height, const UnsignedInt depth,\n+    const UnsignedInt components, const UnsignedByte dimensions)\n+{\n+    const unsigned int numPixels = width * height * depth;\n+    const unsigned int size = numPixels * components;\n+\n+    /* load image data */\n+    char *data = new char[size];\n+    _in->read(data, size);\n+\n+    ColorFormat newColorFormat = format;\n+    if (format == ColorFormat::BGR) {\n+        Debug() << \"Converting from BGR to RGB\";\n+        convertBGRToRGB(data, numPixels);\n+        newColorFormat = ColorFormat::RGB;\n+    } else if (format == ColorFormat::BGRA) {\n+        Debug() << \"Converting from BGRA to RGBA\";\n+        convertBGRAToRGBA(data, numPixels);\n+        newColorFormat = ColorFormat::RGBA;\n+    }\n+\n+    if (dimensions == 2) {\n+        _imageData2D.emplace_back(newColorFormat, ColorType::UnsignedByte, Vector2i{Int(width), Int(height)}, std::move(static_cast<void*>(data)));\n+    } else if (dimensions == 3) {\n+        _imageData3D.emplace_back(newColorFormat, ColorType::UnsignedByte, Vector3i{Int(width), Int(height), Int(depth)}, std::move(static_cast<void*>(data)));\n+    } else {\n+        Error() << \"Unsupported image dimensions:\" << dimensions;\n+    }\n+}\n+\n+void DdsImporter::loadCompressedImageData(const CompressedColorFormat format,\n+    const UnsignedInt width, const UnsignedInt height,\n+    const UnsignedInt depth, const UnsignedByte dimensions)\n+{\n+    const unsigned int size = (depth*((width + 3)/4)*(((height + 3)/4))*((format == CompressedColorFormat::RGBAS3tcDxt1) ? 8 : 16));\n+\n+    /* load image data */\n+    char *data = new char[size];\n+    _in->read(data, size);\n+\n+    if (dimensions == 2) {\n+        _imageData2D.emplace_back(format, Vector2i{Int(width), Int(height)}, Containers::Array<char>(data, size));\n+    } else if (dimensions == 3) {\n+        _imageData3D.emplace_back(format, Vector3i{Int(width), Int(height), Int(depth)}, Containers::Array<char>(data, size));\n+    } else {\n+        Error() << \"Unsupported image dimensions:\" << dimensions;\n+    }\n+}\n+\n+void DdsImporter::doOpenFile(const std::string& filename) {\n+    /* let doOpenData handle it */\n+    AbstractImporter::doOpenFile(filename);\n+}","path":"src/MagnumPlugins/DdsImporter/DdsImporter.cpp","position":365,"original_position":365,"commit_id":"2e7cb9c323fcdf55867a4d24b3833538204270cb","original_commit_id":"2e7cb9c323fcdf55867a4d24b3833538204270cb","user":{"login":"Squareys","id":1889284,"avatar_url":"https://avatars.githubusercontent.com/u/1889284?v=3","gravatar_id":"","url":"https://api.github.com/users/Squareys","html_url":"https://github.com/Squareys","followers_url":"https://api.github.com/users/Squareys/followers","following_url":"https://api.github.com/users/Squareys/following{/other_user}","gists_url":"https://api.github.com/users/Squareys/gists{/gist_id}","starred_url":"https://api.github.com/users/Squareys/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Squareys/subscriptions","organizations_url":"https://api.github.com/users/Squareys/orgs","repos_url":"https://api.github.com/users/Squareys/repos","events_url":"https://api.github.com/users/Squareys/events{/privacy}","received_events_url":"https://api.github.com/users/Squareys/received_events","type":"User","site_admin":false},"body":"Alright, good to know :D","created_at":"2015-08-10T15:58:47Z","updated_at":"2015-08-10T15:58:47Z","html_url":"https://github.com/mosra/magnum-plugins/pull/7#discussion_r36648152","pull_request_url":"https://api.github.com/repos/mosra/magnum-plugins/pulls/7","_links":{"self":{"href":"https://api.github.com/repos/mosra/magnum-plugins/pulls/comments/36648152"},"html":{"href":"https://github.com/mosra/magnum-plugins/pull/7#discussion_r36648152"},"pull_request":{"href":"https://api.github.com/repos/mosra/magnum-plugins/pulls/7"}}},"pull_request":{"url":"https://api.github.com/repos/mosra/magnum-plugins/pulls/7","id":41971338,"html_url":"https://github.com/mosra/magnum-plugins/pull/7","diff_url":"https://github.com/mosra/magnum-plugins/pull/7.diff","patch_url":"https://github.com/mosra/magnum-plugins/pull/7.patch","issue_url":"https://api.github.com/repos/mosra/magnum-plugins/issues/7","number":7,"state":"open","locked":false,"title":"[WIP] DDS import","user":{"login":"Squareys","id":1889284,"avatar_url":"https://avatars.githubusercontent.com/u/1889284?v=3","gravatar_id":"","url":"https://api.github.com/users/Squareys","html_url":"https://github.com/Squareys","followers_url":"https://api.github.com/users/Squareys/followers","following_url":"https://api.github.com/users/Squareys/following{/other_user}","gists_url":"https://api.github.com/users/Squareys/gists{/gist_id}","starred_url":"https://api.github.com/users/Squareys/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Squareys/subscriptions","organizations_url":"https://api.github.com/users/Squareys/orgs","repos_url":"https://api.github.com/users/Squareys/repos","events_url":"https://api.github.com/users/Squareys/events{/privacy}","received_events_url":"https://api.github.com/users/Squareys/received_events","type":"User","site_admin":false},"body":"Hi @mosra !\r\n\r\nAs promissed, here is the WIP Pullrequest. The tests currently still fail and print two identical arrays (for compressed images). For uncompressed, the size of the imagedata seems larger than it should, did not figure out why that is yet (the size calculated correctly in the importer).\r\n\r\nCurrent features/TODOs:\r\n - [x] Uncompressed RGB\r\n - [x] Uncompressed RGBA\r\n - [x] DXT(1|3|5) Compressed images\r\n - [x] Mipmaps (untested for compressed images)\r\n - [x] Cubemaps (untested)\r\n - [x] 3D Textures\r\n - [ ] DXT10? \r\n\r\nGreetings, \r\nSquareys :)","created_at":"2015-08-09T14:39:40Z","updated_at":"2015-08-10T15:58:47Z","closed_at":null,"merged_at":null,"merge_commit_sha":"76254054799a27008a9fce79f0acd6a2f3732570","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mosra/magnum-plugins/pulls/7/commits","review_comments_url":"https://api.github.com/repos/mosra/magnum-plugins/pulls/7/comments","review_comment_url":"https://api.github.com/repos/mosra/magnum-plugins/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mosra/magnum-plugins/issues/7/comments","statuses_url":"https://api.github.com/repos/mosra/magnum-plugins/statuses/2e7cb9c323fcdf55867a4d24b3833538204270cb","head":{"label":"Squareys:dds-importer","ref":"dds-importer","sha":"2e7cb9c323fcdf55867a4d24b3833538204270cb","user":{"login":"Squareys","id":1889284,"avatar_url":"https://avatars.githubusercontent.com/u/1889284?v=3","gravatar_id":"","url":"https://api.github.com/users/Squareys","html_url":"https://github.com/Squareys","followers_url":"https://api.github.com/users/Squareys/followers","following_url":"https://api.github.com/users/Squareys/following{/other_user}","gists_url":"https://api.github.com/users/Squareys/gists{/gist_id}","starred_url":"https://api.github.com/users/Squareys/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Squareys/subscriptions","organizations_url":"https://api.github.com/users/Squareys/orgs","repos_url":"https://api.github.com/users/Squareys/repos","events_url":"https://api.github.com/users/Squareys/events{/privacy}","received_events_url":"https://api.github.com/users/Squareys/received_events","type":"User","site_admin":false},"repo":{"id":40075154,"name":"magnum-plugins","full_name":"Squareys/magnum-plugins","owner":{"login":"Squareys","id":1889284,"avatar_url":"https://avatars.githubusercontent.com/u/1889284?v=3","gravatar_id":"","url":"https://api.github.com/users/Squareys","html_url":"https://github.com/Squareys","followers_url":"https://api.github.com/users/Squareys/followers","following_url":"https://api.github.com/users/Squareys/following{/other_user}","gists_url":"https://api.github.com/users/Squareys/gists{/gist_id}","starred_url":"https://api.github.com/users/Squareys/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Squareys/subscriptions","organizations_url":"https://api.github.com/users/Squareys/orgs","repos_url":"https://api.github.com/users/Squareys/repos","events_url":"https://api.github.com/users/Squareys/events{/privacy}","received_events_url":"https://api.github.com/users/Squareys/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Squareys/magnum-plugins","description":"Plugins for Magnum graphics engine","fork":true,"url":"https://api.github.com/repos/Squareys/magnum-plugins","forks_url":"https://api.github.com/repos/Squareys/magnum-plugins/forks","keys_url":"https://api.github.com/repos/Squareys/magnum-plugins/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Squareys/magnum-plugins/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Squareys/magnum-plugins/teams","hooks_url":"https://api.github.com/repos/Squareys/magnum-plugins/hooks","issue_events_url":"https://api.github.com/repos/Squareys/magnum-plugins/issues/events{/number}","events_url":"https://api.github.com/repos/Squareys/magnum-plugins/events","assignees_url":"https://api.github.com/repos/Squareys/magnum-plugins/assignees{/user}","branches_url":"https://api.github.com/repos/Squareys/magnum-plugins/branches{/branch}","tags_url":"https://api.github.com/repos/Squareys/magnum-plugins/tags","blobs_url":"https://api.github.com/repos/Squareys/magnum-plugins/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Squareys/magnum-plugins/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Squareys/magnum-plugins/git/refs{/sha}","trees_url":"https://api.github.com/repos/Squareys/magnum-plugins/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Squareys/magnum-plugins/statuses/{sha}","languages_url":"https://api.github.com/repos/Squareys/magnum-plugins/languages","stargazers_url":"https://api.github.com/repos/Squareys/magnum-plugins/stargazers","contributors_url":"https://api.github.com/repos/Squareys/magnum-plugins/contributors","subscribers_url":"https://api.github.com/repos/Squareys/magnum-plugins/subscribers","subscription_url":"https://api.github.com/repos/Squareys/magnum-plugins/subscription","commits_url":"https://api.github.com/repos/Squareys/magnum-plugins/commits{/sha}","git_commits_url":"https://api.github.com/repos/Squareys/magnum-plugins/git/commits{/sha}","comments_url":"https://api.github.com/repos/Squareys/magnum-plugins/comments{/number}","issue_comment_url":"https://api.github.com/repos/Squareys/magnum-plugins/issues/comments{/number}","contents_url":"https://api.github.com/repos/Squareys/magnum-plugins/contents/{+path}","compare_url":"https://api.github.com/repos/Squareys/magnum-plugins/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Squareys/magnum-plugins/merges","archive_url":"https://api.github.com/repos/Squareys/magnum-plugins/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Squareys/magnum-plugins/downloads","issues_url":"https://api.github.com/repos/Squareys/magnum-plugins/issues{/number}","pulls_url":"https://api.github.com/repos/Squareys/magnum-plugins/pulls{/number}","milestones_url":"https://api.github.com/repos/Squareys/magnum-plugins/milestones{/number}","notifications_url":"https://api.github.com/repos/Squareys/magnum-plugins/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Squareys/magnum-plugins/labels{/name}","releases_url":"https://api.github.com/repos/Squareys/magnum-plugins/releases{/id}","created_at":"2015-08-02T09:45:26Z","updated_at":"2015-08-02T09:45:27Z","pushed_at":"2015-08-10T15:09:02Z","git_url":"git://github.com/Squareys/magnum-plugins.git","ssh_url":"git@github.com:Squareys/magnum-plugins.git","clone_url":"https://github.com/Squareys/magnum-plugins.git","svn_url":"https://github.com/Squareys/magnum-plugins","homepage":"http://mosra.cz/blog/magnum.php","size":1471,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"mosra:master","ref":"master","sha":"6c72c80673e7a084f3dd9f20a22ddf004125542f","user":{"login":"mosra","id":344828,"avatar_url":"https://avatars.githubusercontent.com/u/344828?v=3","gravatar_id":"","url":"https://api.github.com/users/mosra","html_url":"https://github.com/mosra","followers_url":"https://api.github.com/users/mosra/followers","following_url":"https://api.github.com/users/mosra/following{/other_user}","gists_url":"https://api.github.com/users/mosra/gists{/gist_id}","starred_url":"https://api.github.com/users/mosra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mosra/subscriptions","organizations_url":"https://api.github.com/users/mosra/orgs","repos_url":"https://api.github.com/users/mosra/repos","events_url":"https://api.github.com/users/mosra/events{/privacy}","received_events_url":"https://api.github.com/users/mosra/received_events","type":"User","site_admin":false},"repo":{"id":2982886,"name":"magnum-plugins","full_name":"mosra/magnum-plugins","owner":{"login":"mosra","id":344828,"avatar_url":"https://avatars.githubusercontent.com/u/344828?v=3","gravatar_id":"","url":"https://api.github.com/users/mosra","html_url":"https://github.com/mosra","followers_url":"https://api.github.com/users/mosra/followers","following_url":"https://api.github.com/users/mosra/following{/other_user}","gists_url":"https://api.github.com/users/mosra/gists{/gist_id}","starred_url":"https://api.github.com/users/mosra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mosra/subscriptions","organizations_url":"https://api.github.com/users/mosra/orgs","repos_url":"https://api.github.com/users/mosra/repos","events_url":"https://api.github.com/users/mosra/events{/privacy}","received_events_url":"https://api.github.com/users/mosra/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mosra/magnum-plugins","description":"Plugins for Magnum graphics engine","fork":false,"url":"https://api.github.com/repos/mosra/magnum-plugins","forks_url":"https://api.github.com/repos/mosra/magnum-plugins/forks","keys_url":"https://api.github.com/repos/mosra/magnum-plugins/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mosra/magnum-plugins/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mosra/magnum-plugins/teams","hooks_url":"https://api.github.com/repos/mosra/magnum-plugins/hooks","issue_events_url":"https://api.github.com/repos/mosra/magnum-plugins/issues/events{/number}","events_url":"https://api.github.com/repos/mosra/magnum-plugins/events","assignees_url":"https://api.github.com/repos/mosra/magnum-plugins/assignees{/user}","branches_url":"https://api.github.com/repos/mosra/magnum-plugins/branches{/branch}","tags_url":"https://api.github.com/repos/mosra/magnum-plugins/tags","blobs_url":"https://api.github.com/repos/mosra/magnum-plugins/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mosra/magnum-plugins/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mosra/magnum-plugins/git/refs{/sha}","trees_url":"https://api.github.com/repos/mosra/magnum-plugins/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mosra/magnum-plugins/statuses/{sha}","languages_url":"https://api.github.com/repos/mosra/magnum-plugins/languages","stargazers_url":"https://api.github.com/repos/mosra/magnum-plugins/stargazers","contributors_url":"https://api.github.com/repos/mosra/magnum-plugins/contributors","subscribers_url":"https://api.github.com/repos/mosra/magnum-plugins/subscribers","subscription_url":"https://api.github.com/repos/mosra/magnum-plugins/subscription","commits_url":"https://api.github.com/repos/mosra/magnum-plugins/commits{/sha}","git_commits_url":"https://api.github.com/repos/mosra/magnum-plugins/git/commits{/sha}","comments_url":"https://api.github.com/repos/mosra/magnum-plugins/comments{/number}","issue_comment_url":"https://api.github.com/repos/mosra/magnum-plugins/issues/comments{/number}","contents_url":"https://api.github.com/repos/mosra/magnum-plugins/contents/{+path}","compare_url":"https://api.github.com/repos/mosra/magnum-plugins/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mosra/magnum-plugins/merges","archive_url":"https://api.github.com/repos/mosra/magnum-plugins/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mosra/magnum-plugins/downloads","issues_url":"https://api.github.com/repos/mosra/magnum-plugins/issues{/number}","pulls_url":"https://api.github.com/repos/mosra/magnum-plugins/pulls{/number}","milestones_url":"https://api.github.com/repos/mosra/magnum-plugins/milestones{/number}","notifications_url":"https://api.github.com/repos/mosra/magnum-plugins/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mosra/magnum-plugins/labels{/name}","releases_url":"https://api.github.com/repos/mosra/magnum-plugins/releases{/id}","created_at":"2011-12-14T20:43:25Z","updated_at":"2015-07-07T17:14:12Z","pushed_at":"2015-08-10T15:09:02Z","git_url":"git://github.com/mosra/magnum-plugins.git","ssh_url":"git@github.com:mosra/magnum-plugins.git","clone_url":"https://github.com/mosra/magnum-plugins.git","svn_url":"https://github.com/mosra/magnum-plugins","homepage":"http://mosra.cz/blog/magnum.php","size":2626,"stargazers_count":8,"watchers_count":8,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":9,"mirror_url":null,"open_issues_count":1,"forks":9,"open_issues":1,"watchers":8,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mosra/magnum-plugins/pulls/7"},"html":{"href":"https://github.com/mosra/magnum-plugins/pull/7"},"issue":{"href":"https://api.github.com/repos/mosra/magnum-plugins/issues/7"},"comments":{"href":"https://api.github.com/repos/mosra/magnum-plugins/issues/7/comments"},"review_comments":{"href":"https://api.github.com/repos/mosra/magnum-plugins/pulls/7/comments"},"review_comment":{"href":"https://api.github.com/repos/mosra/magnum-plugins/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mosra/magnum-plugins/pulls/7/commits"},"statuses":{"href":"https://api.github.com/repos/mosra/magnum-plugins/statuses/2e7cb9c323fcdf55867a4d24b3833538204270cb"}}}}