add export layers, export png, import brush padding
This commit is contained in:
@@ -65,9 +65,14 @@ void NodePanelBrush::init()
|
||||
|
||||
std::string path_high = App::I.data_path + "/brushes/" + name + ".png";
|
||||
std::string path_thumb = App::I.data_path + "/brushes/thumbs/" + name + ".png";
|
||||
|
||||
img = img.resize_squared();
|
||||
img.gayscale_alpha();
|
||||
|
||||
auto thumb = img.resize(64, 64);
|
||||
thumb.save(path_thumb);
|
||||
img.save(path_high);
|
||||
auto po2 = img.resize_power2();
|
||||
po2.save(path_high);
|
||||
|
||||
async_start();
|
||||
NodeButtonBrush* brush = new NodeButtonBrush;
|
||||
@@ -75,7 +80,7 @@ void NodePanelBrush::init()
|
||||
brush->init();
|
||||
brush->create();
|
||||
brush->loaded();
|
||||
brush->set_icon(path.c_str());
|
||||
brush->set_icon(path_thumb.c_str());
|
||||
brush->thumb_path = path_thumb;
|
||||
brush->high_path = path_high;
|
||||
brush->brush_name = name;
|
||||
|
||||
Reference in New Issue
Block a user