{"action":"created","issue":{"url":"https://api.github.com/repos/Treinetic/ImageArtist/issues/17","repository_url":"https://api.github.com/repos/Treinetic/ImageArtist","labels_url":"https://api.github.com/repos/Treinetic/ImageArtist/issues/17/labels{/name}","comments_url":"https://api.github.com/repos/Treinetic/ImageArtist/issues/17/comments","events_url":"https://api.github.com/repos/Treinetic/ImageArtist/issues/17/events","html_url":"https://github.com/Treinetic/ImageArtist/issues/17","id":283186375,"number":17,"title":"Pink background instead of transparancy","user":{"login":"BrainFeeder","id":4141465,"avatar_url":"https://avatars3.githubusercontent.com/u/4141465?v=4","gravatar_id":"","url":"https://api.github.com/users/BrainFeeder","html_url":"https://github.com/BrainFeeder","followers_url":"https://api.github.com/users/BrainFeeder/followers","following_url":"https://api.github.com/users/BrainFeeder/following{/other_user}","gists_url":"https://api.github.com/users/BrainFeeder/gists{/gist_id}","starred_url":"https://api.github.com/users/BrainFeeder/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BrainFeeder/subscriptions","organizations_url":"https://api.github.com/users/BrainFeeder/orgs","repos_url":"https://api.github.com/users/BrainFeeder/repos","events_url":"https://api.github.com/users/BrainFeeder/events{/privacy}","received_events_url":"https://api.github.com/users/BrainFeeder/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2017-12-19T10:59:32Z","updated_at":"2018-03-08T07:30:39Z","closed_at":"2018-03-08T07:30:39Z","author_association":"NONE","body":"#13 is about the same issue..\r\n\r\nMy transparent background color displays as pink.\r\n\r\n![merged](https://user-images.githubusercontent.com/4141465/34153499-9638c784-e4b2-11e7-8a61-89e58ab2e354.png)\r\n\r\nI wanted to do something like Facebook does for group chats: merging participant avatars to be one image. Code I have:\r\n\r\n    //$overlayWhite = new Overlay($size,$size,new Color(255,255,255)); I get the same if I use this instead of circle.png\r\n    $background = new CircularShape(FCPATH.'public/loremipsum/img/users/circle.png');\r\n    $background->build();\r\n\r\n    foreach($users as $i => $user) {\r\n        $file = str_replace(img_url(), FCPATH.'public/loremipsum/img/', $user->getAvatar());\r\n        $img = new Square($file);\r\n        $img->setDefaults();\r\n        $img->resize($size/2,$size/2);\r\n        //$offsetX = ($img->getWidth()-$size)/2;\r\n        //$offsetY = ($img->getHeight()-$size)/2;\r\n        //$img->crop($offsetX , $offsetY, 32, 32); crop don't does what I expected... Probably beacause of #16 \r\n        $img->build();\r\n\r\n        switch($i) { $background = $background->merge($img,$w,$h); } // just to give an idea of merging, I select up to 4 avatars zo they get positioned in each corner of main image ($background).. \r\n        // This works so not showing all code\r\n        \r\n    }\r\n    return $background->getDataURI();\r\n\r\nAnd another unexpected behaviour: I hoped using circularShape would cut of corners from merged squares, so the resulting image would be a circle."},"comment":{"url":"https://api.github.com/repos/Treinetic/ImageArtist/issues/comments/371403960","html_url":"https://github.com/Treinetic/ImageArtist/issues/17#issuecomment-371403960","issue_url":"https://api.github.com/repos/Treinetic/ImageArtist/issues/17","id":371403960,"user":{"login":"imalhasaranga","id":1076374,"avatar_url":"https://avatars0.githubusercontent.com/u/1076374?v=4","gravatar_id":"","url":"https://api.github.com/users/imalhasaranga","html_url":"https://github.com/imalhasaranga","followers_url":"https://api.github.com/users/imalhasaranga/followers","following_url":"https://api.github.com/users/imalhasaranga/following{/other_user}","gists_url":"https://api.github.com/users/imalhasaranga/gists{/gist_id}","starred_url":"https://api.github.com/users/imalhasaranga/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/imalhasaranga/subscriptions","organizations_url":"https://api.github.com/users/imalhasaranga/orgs","repos_url":"https://api.github.com/users/imalhasaranga/repos","events_url":"https://api.github.com/users/imalhasaranga/events{/privacy}","received_events_url":"https://api.github.com/users/imalhasaranga/received_events","type":"User","site_admin":false},"created_at":"2018-03-08T07:30:38Z","updated_at":"2018-03-08T07:30:38Z","author_association":"CONTRIBUTOR","body":" @BrainFeeder I think @antondias  is correct,  follow his code also please upgrade to latest ImageArtist Version, i'm closing this issue making as not reproducible issue "}}
{"actor":{"display_login":"imalhasaranga"}}