diff options
| author | Juan Linietsky | 2017-05-17 07:36:47 -0300 |
|---|---|---|
| committer | Juan Linietsky | 2017-05-17 07:37:45 -0300 |
| commit | 98a329670227c726a5d7a196e5cba8dbdd54301b (patch) | |
| tree | 7346f7a3e38eb35b784ac1a68a227d07cc8881b4 /editor/editor_profiler.cpp | |
| parent | d801ff2b3db2de105c1b36a74ce116e360143d4e (diff) | |
| download | godot-98a329670227c726a5d7a196e5cba8dbdd54301b.tar.gz godot-98a329670227c726a5d7a196e5cba8dbdd54301b.tar.zst godot-98a329670227c726a5d7a196e5cba8dbdd54301b.zip | |
Removal of Image from Variant, converted to a Resource.
Diffstat (limited to 'editor/editor_profiler.cpp')
| -rw-r--r-- | editor/editor_profiler.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/editor/editor_profiler.cpp b/editor/editor_profiler.cpp index 8f4312111..9d12ad687 100644 --- a/editor/editor_profiler.cpp +++ b/editor/editor_profiler.cpp @@ -344,14 +344,16 @@ void EditorProfiler::_update_plot() { wr = PoolVector<uint8_t>::Write(); - Image img(w, h, 0, Image::FORMAT_RGBA8, graph_image); + Ref<Image> img; + img.instance(); + img->create(w, h, 0, Image::FORMAT_RGBA8, graph_image); if (reset_texture) { if (graph_texture.is_null()) { graph_texture.instance(); } - graph_texture->create(img.get_width(), img.get_height(), img.get_format(), Texture::FLAG_VIDEO_SURFACE); + graph_texture->create(img->get_width(), img->get_height(), img->get_format(), Texture::FLAG_VIDEO_SURFACE); } graph_texture->set_data(img); |
