Jump to content

Dev update #22: Mine-imator 2.0 in C++!?


Recommended Posts

On 5/1/2022 at 11:05 AM, My name is North_Xv said:

SO COOL!But my biggest expectation is that Mine-imator can support more languages, because my English is actually not very good!

I translated the MB tho. And for MI20 later after it released.

 

Link to post
Share on other sites

On 17.04.2022 at 23:08, david said:

Привет!

В преддверии 10-летнего юбилея Mine- imator я решил временно присоединиться к команде разработчиков и добавить несколько давно запрошенных функций, которые вы вскоре сможете загрузить в грядущей предварительной версии 2.0, которая выйдет в конце мая/начале июня

@Нимипроделал феноменальную работу над новыми функциями (многие еще даже не анонсированы!), однако используемый графический движок (GameMaker) был большим препятствием на пути оптимизации программного обеспечения и обеспечения хорошей частоты кадров и использования памяти со всеми новыми дополнениями. Поэтому я вскочил, чтобы протянуть руку помощи, и мне, наконец, удалось успешно перенести Mine-imator на новый графический движок с использованием языка программирования C++ для повышения производительности, оптимизации памяти (x64) и поддержки нескольких платформ. Все технические подробности смотрите внизу поста.

Чтобы облегчить разработку, мы очень ценим вашу поддержку на протяжении многих лет, создание и обмен контентом, предложения, сообщения об ошибках и особенно пожертвования! Mine-imator в течение последнего десятилетия был полностью бесплатным и останется таковым , но ваши пожертвования помогли сохранить его жизнь за счет затрат на веб-сервер и напрямую профинансировали разработку версии 2.0 (например, для этого обновления мне пришлось получить MacBook 😉). Если вы еще не сделали пожертвование команде разработчиков или хотите продолжить поддержку, перейдите по ссылке ниже:

Пожертвовать на развитие Mine-imator ($5+ разово или регулярно)

Помимо всего этого, давайте перейдем к новым функциям, обнаруженным в первом предварительном выпуске 2.0, за которым последовали дополнительные выпуски с изменениями пользовательского интерфейса Ними, улучшениями анимации и функциями рендеринга (см. Обновление от разработчиков № 21 )!

Давайте получить HYPED! 8D 8D 8D

 

Начнем с небольшого, но полезного, действительно работающего параметра «Отмена» при нажатии кнопки X!

8ZFdXGP.gif 

 

Далее кое-что для мультимониторных аниматоров: больше никаких переполненных рабочих мест, просто отсоедините временную шкалу или вид с камеры во втором окне и перетащите их на другой экран!

21qnie5.gif 

u2yyboA.jpg

 

Загрузка файла Scenery/.schematic была многопоточной и оптимизирована, чтобы быть примерно в 10 раз быстрее, а также занимать меньше памяти, что позволяет использовать гораздо большие области, чем раньше! Кроме того, декорации кешируются и мгновенно загружаются при повторном открытии вашего проекта (без полосы загрузки).

ioQM3lD.gif 

 

Mine-imator скоро сможет обрабатывать гораздо более сложные проекты с ускорением в 3-5 раз по сравнению с более ранними версиями при рендеринге многих объектов. Это стало возможным благодаря оптимизации ЦП и объединению объектов в пакеты перед отправкой их на графический процессор для рендеринга (Mine-imator не будет выделять больше ресурсов ЦП по сравнению с текущими версиями, а просто будет использовать их более эффективно).

ПальТвуг.jpg

 

Пользователи Linux не могут использовать Mine-imator в течение 10 лет, но не больше! Версия 2.0 будет без проблем работать в операционных системах Debian/Ubuntu со всеми теми же функциями!
(PS Если у вас есть другой любимый дистрибутив Linux, сообщите нам об этом)

GB2Jbh3.jpg

 

То же самое касается пользователей Mac OS после бесчисленных запросов!

SUsZJiv.jpg

 

Наконец, опция «Импорт из мира» была полностью переработана, чтобы иметь 3D-интерфейс для более легкого выбора части вашего мира для анимации. Несмотря на то, что он 3D и имеет больше возможностей, он также будет загружать миры намного быстрее по сравнению с текущей версией и в целом будет более стабильным. Он также будет интегрирован в программное обеспечение, а не открывать всплывающее окно, и будет доступен с помощью ярлыка на панели инструментов.

EQUov9p.jpg

hRcvt3J.gif 

 

За кулисами порта 2.0 C++:
(Всё будет технически и заумно, вас предупредили!!)

  Показать скрытое содержимое

Porting Mine-imator away from GameMaker has been attempted several times in the past and was known for being an extremely laborious and complex task, sure to take years if attempted manually. For reference, the current codebase is well over 90,000 lines of code (think of each line as an instruction, each feature consisting of an intertwined network of thousands of lines) making it a huge task for anyone to tackle, given all the features added over 10 years by multiple developers. This is not to mention the extra code needed to fill in the gaps of the GameMaker functionality used, such as drawing the GUI, handling keyboard/mouse input and rendering geometry using shaders. The end goal would be to switch from GameMaker Language (GML) into a new chosen programming language with more performance, memory management and multi-platform capabilities, where C++ was chosen as the best option.

Given the nature of the task, I decided roughly 3 months ago to try a new approach for 2.0 and automatically have a script read the files in the codebase, figure out the functions and variables used and convert it line-by-line to working (and heavily optimized) C++ code. Having a program to act as a compiler of-sorts and convert between GML->C++ would also allow the team to keep using GameMaker as the development tool (IDE) for testing, while having the benefits of C++ for the final build released to the public.

After some experimentation I was able to convert the entire codebase into C++ using a C# script, taking no less than 20 seconds (compared to the years it would take manually). The problem still persisted of filling in said gaps of the GameMaker functionality which is where the majority of the remaining work was, along with making sure the converted code was bug-free and achieved the exact same behavior as the GML by carefully comparing the behavior of 1.2.9 and the C++ version of 1.2.9.

See below for a snippet of GML code on the left and the converted C++ counterpart on the right (created automatically in a few milliseconds by the script). Doing this manually and testing it to make sure it works and fixing the resulting bugs introduced by common mistakes would potentially take hours.

DZqlPbp.png 

After the code was ported, I started looking into new features that could be added in this new C++ environment that were previously impossible in GameMaker, including optimizing the performance further, adding multi-threading, multl-monitor support, more advanced 3D rendering (such batch rendering and boosting the world importer) and the heavily requested Mac OS/Linux support.

To conclude, after many years I’ve been able to port Mine-imator to C++, which has without doubt been the most challenging programming task I’ve done but has taught me a lot and I hope the resulting improvements and features will be appreciated by countless animators for another 10 years ahead!


Обязательно следите за предстоящими предварительными выпусками, следите за нашей страницей в Твиттере или присоединяйтесь к нашему чату в Discord. 😎✌️

Еще раз спасибо за всю поддержку на протяжении многих лет и продолжайте анимировать нашу любимую блочную игру!

/Дэйвид
 

My question is: Will the support and import of models from the block bench be improved?  I often encounter a problem when importing textures and models themselves, in principle, the model system is very poorly made:(

Link to post
Share on other sites

On 4/17/2022 at 12:08 PM, david said:

Greetings!

With the 10 year anniversary of Mine-imator coming up, I’ve decided to temporarily rejoin the developer team and add some long requested features you will soon be able to download in an upcoming version 2.0 pre-release arriving late May/early June

@Nimi has done some phenomenal work on new features (many not even announced yet!), however the graphics engine used (GameMaker) has been a big obstacle towards optimizing the software and ensuring good framerates and memory usage with all the new additions. Therefore I have jumped in to lend a hand and I've finally been able to successfully migrate Mine-imator to a new graphics engine using the C++ programming language for added performance, optimized memory (x64) and multi-platform support. For all the technical details see the bottom of the post.

In order to facilitate the development we have greatly appreciated your support throughout the years, creating and sharing content, giving suggestions, reporting bugs and especially with donations! Mine-imator has for the past decade been completely free and will remain so, but your donations have helped keep it alive with webserver costs and directly funded the development of version 2.0 (for instance, I had to get a MacBook for this update 😉). If you have not donated yet to the development team or wish to continue supporting, see the link below:

Donate to Mine-imator development ($5+ one-time or recurring)

With all that aside, let’s get to the new features found in the first 2.0 pre-release, later followed by additional releases with Nimi’s UI changes, animation improvements and rendering features (See Dev Update #21)!

Let’s get HYPED! 8D 8D 8D

 

Starting off small yet useful, an actually working Cancel option when clicking the program’s X!

8ZFdXGP.gif 

 

Next up something for the multi-monitor animators: No more crammed workspaces, simply detach your timeline or camera view into a second window and drag it to another screen!

21qnie5.gif 

u2yyboA.jpg

 

Scenery/.schematic file loading has been multi-threaded and optimized to be around 10 times faster as well as taking up less memory, allowing much bigger regions than before! In addition, the scenery is cached and instantly loaded upon re-opening your project (with no loading bar).

ioQM3lD.gif 

 

Mine-imator will soon be able to handle much more complex projects with a speedup between 3-5 times compared to earlier versions when rendering many objects. This is made possible with CPU optimizations and combining objects into batches before sending them to the GPU for rendering (Mine-imator will not be allocating more CPU resources compared to current versions, just using them more efficiently).

pAlTvug.jpg

 

Linux users have been left out of using Mine-imator for 10 years, but no more! Version 2.0 will run smoothly on Debian/Ubuntu operating systems with all the same features!
(P.S. If you have another favorite Linux distribution let us know)

GB2Jbh3.jpg

 

Same goes for Mac OS users after countless requests!

SUsZJiv.jpg

 

Finally, the “Import from World” option has been completely reworked to have a 3D interface for more easily selecting a section of your world to animate. Despite being 3D and having more options, it will also load worlds much more quickly compared to the current version and in general be more stable. It will also be integrated into the software rather than opening a pop-up window, and accessed with a shortcut in the toolbar.

EQUov9p.jpg

hRcvt3J.gif 

 

Behind the scenes of the 2.0 C++ port:
(Things will get technical and nerdy, you have been warned!!)

  Reveal hidden contents

Porting Mine-imator away from GameMaker has been attempted several times in the past and was known for being an extremely laborious and complex task, sure to take years if attempted manually. For reference, the current codebase is well over 90,000 lines of code (think of each line as an instruction, each feature consisting of an intertwined network of thousands of lines) making it a huge task for anyone to tackle, given all the features added over 10 years by multiple developers. This is not to mention the extra code needed to fill in the gaps of the GameMaker functionality used, such as drawing the GUI, handling keyboard/mouse input and rendering geometry using shaders. The end goal would be to switch from GameMaker Language (GML) into a new chosen programming language with more performance, memory management and multi-platform capabilities, where C++ was chosen as the best option.

Given the nature of the task, I decided roughly 3 months ago to try a new approach for 2.0 and automatically have a script read the files in the codebase, figure out the functions and variables used and convert it line-by-line to working (and heavily optimized) C++ code. Having a program to act as a compiler of-sorts and convert between GML->C++ would also allow the team to keep using GameMaker as the development tool (IDE) for testing, while having the benefits of C++ for the final build released to the public.

After some experimentation I was able to convert the entire codebase into C++ using a C# script, taking no less than 20 seconds (compared to the years it would take manually). The problem still persisted of filling in said gaps of the GameMaker functionality which is where the majority of the remaining work was, along with making sure the converted code was bug-free and achieved the exact same behavior as the GML by carefully comparing the behavior of 1.2.9 and the C++ version of 1.2.9.

See below for a snippet of GML code on the left and the converted C++ counterpart on the right (created automatically in a few milliseconds by the script). Doing this manually and testing it to make sure it works and fixing the resulting bugs introduced by common mistakes would potentially take hours.

DZqlPbp.png 

After the code was ported, I started looking into new features that could be added in this new C++ environment that were previously impossible in GameMaker, including optimizing the performance further, adding multi-threading, multl-monitor support, more advanced 3D rendering (such batch rendering and boosting the world importer) and the heavily requested Mac OS/Linux support.

To conclude, after many years I’ve been able to port Mine-imator to C++, which has without doubt been the most challenging programming task I’ve done but has taught me a lot and I hope the resulting improvements and features will be appreciated by countless animators for another 10 years ahead!


Be sure to keep an eye out for the upcoming pre-releases, following our Twitter page or joining our Discord chat might be a good idea. 😎✌️

Once again thank you for all the support through the years and keep on animating our favorite block game!

/David
 

Sorry if I replied to this wrong. But I was wondering if there could be support for Manjaro Linux if there isn't already? Thank you for your time I hope you have a great day. :D.

Manjaro Linux: https://manjaro.org/

Link to post
Share on other sites

On 4/17/2022 at 7:08 PM, david said:

Greetings!

With the 10 year anniversary of Mine-imator coming up, I’ve decided to temporarily rejoin the developer team and add some long requested features you will soon be able to download in an upcoming version 2.0 pre-release arriving late May/early June

@Nimi has done some phenomenal work on new features (many not even announced yet!), however the graphics engine used (GameMaker) has been a big obstacle towards optimizing the software and ensuring good framerates and memory usage with all the new additions. Therefore I have jumped in to lend a hand and I've finally been able to successfully migrate Mine-imator to a new graphics engine using the C++ programming language for added performance, optimized memory (x64) and multi-platform support. For all the technical details see the bottom of the post.

In order to facilitate the development we have greatly appreciated your support throughout the years, creating and sharing content, giving suggestions, reporting bugs and especially with donations! Mine-imator has for the past decade been completely free and will remain so, but your donations have helped keep it alive with webserver costs and directly funded the development of version 2.0 (for instance, I had to get a MacBook for this update 😉). If you have not donated yet to the development team or wish to continue supporting, see the link below:

Donate to Mine-imator development ($5+ one-time or recurring)

With all that aside, let’s get to the new features found in the first 2.0 pre-release, later followed by additional releases with Nimi’s UI changes, animation improvements and rendering features (See Dev Update #21)!

Let’s get HYPED! 8D 8D 8D

 

Starting off small yet useful, an actually working Cancel option when clicking the program’s X!

8ZFdXGP.gif 

 

Next up something for the multi-monitor animators: No more crammed workspaces, simply detach your timeline or camera view into a second window and drag it to another screen!

21qnie5.gif 

u2yyboA.jpg

 

Scenery/.schematic file loading has been multi-threaded and optimized to be around 10 times faster as well as taking up less memory, allowing much bigger regions than before! In addition, the scenery is cached and instantly loaded upon re-opening your project (with no loading bar).

ioQM3lD.gif 

 

Mine-imator will soon be able to handle much more complex projects with a speedup between 3-5 times compared to earlier versions when rendering many objects. This is made possible with CPU optimizations and combining objects into batches before sending them to the GPU for rendering (Mine-imator will not be allocating more CPU resources compared to current versions, just using them more efficiently).

pAlTvug.jpg

 

Linux users have been left out of using Mine-imator for 10 years, but no more! Version 2.0 will run smoothly on Debian/Ubuntu operating systems with all the same features!
(P.S. If you have another favorite Linux distribution let us know)

GB2Jbh3.jpg

 

Same goes for Mac OS users after countless requests!

SUsZJiv.jpg

 

Finally, the “Import from World” option has been completely reworked to have a 3D interface for more easily selecting a section of your world to animate. Despite being 3D and having more options, it will also load worlds much more quickly compared to the current version and in general be more stable. It will also be integrated into the software rather than opening a pop-up window, and accessed with a shortcut in the toolbar.

EQUov9p.jpg

hRcvt3J.gif 

 

Behind the scenes of the 2.0 C++ port:
(Things will get technical and nerdy, you have been warned!!)

  Reveal hidden contents

Porting Mine-imator away from GameMaker has been attempted several times in the past and was known for being an extremely laborious and complex task, sure to take years if attempted manually. For reference, the current codebase is well over 90,000 lines of code (think of each line as an instruction, each feature consisting of an intertwined network of thousands of lines) making it a huge task for anyone to tackle, given all the features added over 10 years by multiple developers. This is not to mention the extra code needed to fill in the gaps of the GameMaker functionality used, such as drawing the GUI, handling keyboard/mouse input and rendering geometry using shaders. The end goal would be to switch from GameMaker Language (GML) into a new chosen programming language with more performance, memory management and multi-platform capabilities, where C++ was chosen as the best option.

Given the nature of the task, I decided roughly 3 months ago to try a new approach for 2.0 and automatically have a script read the files in the codebase, figure out the functions and variables used and convert it line-by-line to working (and heavily optimized) C++ code. Having a program to act as a compiler of-sorts and convert between GML->C++ would also allow the team to keep using GameMaker as the development tool (IDE) for testing, while having the benefits of C++ for the final build released to the public.

After some experimentation I was able to convert the entire codebase into C++ using a C# script, taking no less than 20 seconds (compared to the years it would take manually). The problem still persisted of filling in said gaps of the GameMaker functionality which is where the majority of the remaining work was, along with making sure the converted code was bug-free and achieved the exact same behavior as the GML by carefully comparing the behavior of 1.2.9 and the C++ version of 1.2.9.

See below for a snippet of GML code on the left and the converted C++ counterpart on the right (created automatically in a few milliseconds by the script). Doing this manually and testing it to make sure it works and fixing the resulting bugs introduced by common mistakes would potentially take hours.

DZqlPbp.png 

After the code was ported, I started looking into new features that could be added in this new C++ environment that were previously impossible in GameMaker, including optimizing the performance further, adding multi-threading, multl-monitor support, more advanced 3D rendering (such batch rendering and boosting the world importer) and the heavily requested Mac OS/Linux support.

To conclude, after many years I’ve been able to port Mine-imator to C++, which has without doubt been the most challenging programming task I’ve done but has taught me a lot and I hope the resulting improvements and features will be appreciated by countless animators for another 10 years ahead!


Be sure to keep an eye out for the upcoming pre-releases, following our Twitter page or joining our Discord chat might be a good idea. 😎✌️

Once again thank you for all the support through the years and keep on animating our favorite block game!

/David
 

Will there be Bedrock Worlds support anytime soon?

Porting worlds to java causes corruption and unwanted results ya know.

Link to post
Share on other sites

Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...