Как выделить блендеру больше оперативной памяти
When it comes to rendering large and intensive scenes in Blender, memory optimization becomes critical. I have lost count of how many times Blender crashed for me thanks to using too much memory during rendering. Many times, the statement less is more, is something to really keep in mind.
These are the primary ways in which we can reduce memory usage in Blender.
- Reduce the amount of geometry.
- Reduce the amount and size of textures.
- Reduce the use of particles and simulation data.
- Free up memory used in other applications.
There are a lot of parameters that dictate memory usage. In this article we will take a deep dive in RAM usage for Blender users and what we can do to be more efficient with our RAM so that we may render those large projects that otherwise leave us with a crash or out of memory error.
How does RAM work in a computer?
In a computer, the operating system is responsible for managing memory. It allocates memory for applications upon request and free memory when it is no longer needed based on what the user is currently doing and what different processes are running. Both in the foreground and in the background.
For instance, the operating system knows what application is currently being used actively and so it prioritizes memory for it along with other resources such as CPU and disk access depending on what it needs.
In the meantime, other applications that are minimized or has not been active for a long time gets less and less priority. At some point the operating system can even start to move data from RAM to the hard drive for later if applications are open for longer periods in the background but isn't vital enough to store in the faster RAM.
On Windows this space on the hard drive is called the swap file while on MacOS and Linux, this isn't a file. Instead, it is a dedicated part of the hard drive called a swap partition.
So, what does this have to do with rendering in Blender?
Reduce memory by using adaptive subdivision
Adaptive subdivision is an experimental feature available in Cycles. Even if it is still considered experimental, it has been around for a long time. Personally, I find it to be stable enough to be used in everyday modeling.
Instead of giving an object a fixed subdivbision, Blender subdivide the object depending on the objects distance from the camera.
Geometry further away get less subdivisions while objects closer to the camera get more dense geometry.
The downside is that it can be challenging to tweak the adaptive subdivision to fit the scene perfectly. With its default settings it tends to add very much geometry for very fine detailed meshes.
This may lead to the opposite effect, using more geometry and memory than initially. So, it is important to tweak and test the settings before committing to a full-scale render.
Another downside is that we can only view the result in rendered mode as the subdivision happens at render time. But we can view the result in rendered preview mode.
To setup adaptive subdivision for an object in Blender follow these steps:
- Switch to Cycles render engine and change the feature set to experimental
- In the render settings, a new section called subdivision appears where we can tweak related settings.
- Add a subdivision surface modifier to your object
- Check "adaptive subdivision"
- Position your camera correctly in relation to your object.
The primary settings to keep in mind when tweaking the adaptive subdivision are the dicing rate render and max subdivisions.
A lower dicing rate will cause more geometry while the max subdivisions set the max allowed subdivisions overall.
Параметры визуализации¶
- Отключите визуализацию Рёбер.
- Сохраняйте буферы.
- Render to a UV/Image Editor , not a pop-up. Render Window .
- На многоядерных процессорах используйте несколько Потоков (с разбиением изображения на несколько Частей).
- Decrease the frame count of the animation (and use a lower frame rate for the same duration of animation). For example, render 30 frames at 10 frames per second for a 3-second animation, instead of 75 frames at 25 frames per second.
- Визуализируйте только интересующие вас слои.
- Визуализируйте все источники света как один простой прожектор (введите его имя в поле Освещение).
- Визуализируйте с переопределением на один материал (введите его имя в поле Материал).
- Отключите ненужные проходы визуализации, например Z, либо отрисовывайте только нужный проход, например, диффузный.
- Отключите тени.
- Отключите карты окружения.
- Отключите панорамную визуализацию.
- Turn off Ray tracing.
- Отключите подповерхностное рассеивание.
- Отключите или уменьшите параметры сглаживания.
- Отключите или уменьшите параметры размытия при движении.
- Производите визуализацию по частям. Также этот совет поможет вам отрисовать очень большие изображения на слабых ПК. На многоядерных ПК можно каждой части назначить своё ядро.
- Увеличьте разрешение октодерева.
- Визуализируйте в процентах от размера вашего окончательного разрешения (например, 25%).
- Отключите визуализацию Полей.
- Используйте Границы визуализации для визуализации только некоторого подмножества полного изображения.
- Bake Full Render creates a UV texture that colors the objects based on materials, and then uses that UV texture shadeless instead of the material.
- Запекайте только Ambient Occlusion.
- Запекайте текстуры для объектов.
- Запекание нормалей и смещений не ускоряет визуализацию и используется для других вещей.
- Визуализируйте в меньшем разрешении. Маленькие изображения требуют меньше времени на визуализацию.
- Выберите более быстрый кодек или настройки кодека.
- Визуализируйте в оттенках серого (кнопка BW).
- При использовании формата FFMPEG не активируйте параметр Multiplex audio (Мультиплексирование звука).
- При использовании формата FFMPEG включите параметр Авторазделение вывода (на панели Кодирование).
- Визуализируйте только RGB, если вам просто нужны цвета; канал прозрачности A (кнопка RGBA) потребляет дополнительную память и не используется при сохранении файла фильма.
Сцена и определённые объекты¶
- Remove lamps, or move them to unrendered layers, or group them into layers.
- Отключите тени от каких-нибудь ламп, для отбрасывания теней используйте только одну или две основных лампы-солнца. Несколько дающих тени ламп будут отрисовываться быстрее, чем если бы каждая лампа давала тень.
- Используйте буферные тени вместо теней от трассировки лучей.
- Запекайте свои тени при помощи запекания полной визуализации на неподвижные поверхности. Используйте получившуюся текстуру для полисетки и отключите тени для её материала.
- Упростите полисетки (удалите полигоны). Чем больше вершин находится в камере, тем больше времени требуется на визуализацию.
- Удалите двойные вершины или используйте функцию редактирования полисетки модификатора «Аппроксимация».
- Удалите модификаторы «Подразделение поверхности» и «Мультиразрешение».
- Удалите задние грани полисеток (невидимую геометрию).
- Визуализируйте за раз только несколько объектов; в начале вашего проекта отрисуйте фоновые объекты и наборы объектов, которые не будут меняться и всегда будут на фоне.
- Поместите строения на отдельный слой, и скройте их от визуализации через слои визуализации. Затем объедините их с остальным изображением на этапе композитинга.
- Сделайте камеру статичной, чтобы лучше выполнить две вышеуказанные идеи.
- Избегайте использования ламп-областей.
- Отключите затенение для материалов.
- Запеките AO и текстуры, а затем отключите затенение для соответствующих материалов.
- Уменьшите расстояние отсечения для ламп-прожекторов.
- Уменьшите расстояние отсечения для камеры.
- Отключите AO окружающей среды.
- Отключите подповерхностное рассеивание материала.
- Используйте текстуры меньшего размера. Изображение размерами 256×256 занимает всего 1% от памяти, требуемой для 2k-изображения и часто в конечной визуализации вообще не происходит потери качества.
- Уменьшите количество подразделений в модификаторе «Подразделение поверхности». Каждый уровень подразделения учетверяет (4x) количество граней по сравнению с предыдущим уровнем.
- Уменьшите мультиразрешение.
- Сделайте маску с отрисованными фоновыми объектами, например, зданиями, и поместите в сцену плоскость с этим изображением вместо самих объектов. Это позволит уменьшить количество вершин/граней.
- If you have lots of linked instances of an object, use DupliFaces, as these are instanced. If you have 100 of them, Blender will only store the geometry for one. (Instances themselves take a small amount of memory).
Using the simplify settings to reduce memory usage
The simplify settings are excellent when we need a quick fix to a heavy scene. We can use the simplify settings to globally reduce memory usage in a few different ways. The simplify settings can be found in the render settings. To enable them tick the checkbox on the simplify section.
The simplify options are slightly different between Eevee and Cycles. But generally, they are the same. I cover the simplify section for Cycles as part of this article here, but we will cover it in this article as well:
Here are the settings.
We can set a max subdivision for all objects in the entire scene. This is a quick way to reduce geometry to a manageable level if you know you have many objects with too much geometry.
The child particles slider is a percentage value from 0 to 1. Decreasing the slider to 0.5 will remove 50% of the child particles for all particle systems in the scene for example.
Texture limit allow us to set a maximum texture size through the entire scene. Any texture larger than this number will be downsized automatically. This however, is only available in Cycles.
The AO bounces isn't really applicable to memory optimization but if you want to know more about it you can read the article linked above.
For Cycles we also have culling in the simplify settings. These are two checkboxes. Camera culling and distance culling.
Distance culling will take objects that are further than the distance specified away from the camera and not render them in the scene.
The Camera culling will disable objects outside the camera's visibility to the left, right as well as above and below. The distance is decided by the slider next to the camera culling option.
For an object to be considered for camera or distance culling though, we need to enable culling for all objects that we want to be affected.
We can do this on an object-by-object basis by selecting an object, go to the object properties and find the visibility section.
Here we find the culling subsection with two checkboxes. One for camera cull and one for distance cull.
To enable these checkboxes for multiple objects, we can select all objects we want to cull, then select one object last to become the active object.
After that, enable culling, right click each checkbox, and choose "Copy to selected". This will copy the specific setting from the active object to all selected objects.
Усовершенствования оборудования¶
- Установите больше системной памяти.
- Обновите ваш центральный процессор до многоядерного/многопроцессорного.
- Обновите свои драйвера OpenGL.
- Поставьте более быструю память, вплоть до предела, который поддерживает ваша материнская плата.
- Используйте или настройте ферму визуализации, используя все имеющиеся компьютеры в вашем доме, либо воспользуйтесь готовой фермой визуализации.
Reduce memory usage by reducing subdivision and multires modifier levels
Let's start by looking at the subdivision surface modifier. This modifier quadruples the amount of geometry for every level of subdivisions we add.
Four times as much data uses up for times as much memory and starting to look through objects where you have a subdivision and decreasing it as much as possible can be enough to save a scene that isn't rendering.
Personally, I try to stick to subdivision levels of 1-3. What you need to keep in mind is that you are far more involved in your project than anybody else. Nobody else see your scene at the same detailed level.
It is rare that people viewing your art complain about an extra level of subdivision if you yourself can barely see the difference. In these cases, the extra geometry is simply not worth the extra memory usage.
The same goes for the multi-resolution modifier. You can stick to 1 level lower than you think you need in most cases.
How can we reduce memory used by particle systems in Blender?
Another substantial source of memory usage is particle systems that we use to distribute objects.
The most common use of particle systems is to distribute a collection of objects across a surface. But there are other uses as well, and depending on your situation you may have different flexibility with how much RAM you can save by optimizing it.
But for the common cases when we distribute objects across a surface, such as grass, greenery, or rocks on the ground or debris in an old house we can use child particles and limit the area we distribute the particles across.
There are two types of child particles distributions. Simple and interpolated. Essentially, they are two different mathematical ways to distribute particles with different settings.
The simple child distribution uses the parent particles position as a starting point when emitting while the interpolated child particles emit between parents and can also themselves become virtual parents.
You can read more about child particles in the Blender manual here.
Personally, I tend to use the interpolated child particles most of the time as it gives more options and a more even distribution.
Before you turn child particles on, reduce your number of particles to one tenth or one hundredths of the original amount so that you avoid Blender freezing for too long and potentially crashing.
The default setting is to emit 10 particles per parent in the viewport and 100 in the final render creating a much denser distribution. You can change these values in the particle system child settings.
Once child particles are setup, we can also create a vertex group if we have some vertex density across our surface. Go to weight paint and paint the area that is in view of the camera.
Then in the particle system settings, find the vertex groups section and the density parameter and select your vertex group here.
This will limit the distribution of particles to only the painted area so that we don't have to emit unnecessary particles that don't contribute to the scene.
Параметры Blender’а¶
- Увеличьте параметр «Ограничение кэша в памяти» в настройках Blender на вкладке «Система» в разделе «OpenGL».
- Переключитесь на ортографическую камеру и визуализируйте «части» сцены в отдельные изображения, а затем соберите их вместе в GIMP. Здесь работает старый трюк с созданием собственной панорамы с реальной камеры, когда вы делаете несколько фотографий очень широкой (закат на пляже) сцены: делаете один снимок, поворачиваетесь направо, делаете другой, потом ещё раз и так далее; и когда вы сделаете все эти фотографии, вы накладываете их друг на друга для получения очень широкого изображения ландшафта. Сделайте то же самое в Blender’е: визуализируйте один снимок в файл, направьте камеру на другую область сцены и сделайте второй снимок. Каждый снимок будет меньшей площади и, таким образом, содержать меньше полигонов/граней. Убедитесь, что, когда вы устанавливаете камеру, вы перекрываете кусочек предыдущего снимка, чтобы потом вы смогли их сопоставить. Если вы не хотите использовать GIMP, вы можете использовать для сопоставления узлы композитора Blender’а, в частности, узел «Перемещение».
- Minimize the render window (and the Blender window, if the UV/Image editor is used). ATI users report dramatic speed-up on a per-frame basis, which adds up over the frame range.
- Используйте скрипт Big Render для визуализации частей общего изображения, а затем объедините их вместе.
Final thoughts
There are quite a few considerations we can keep in mind as we create our scenes. Not only artistic, but also technical that can help us not only improve the memory usage, but also give us a smoother work experience along the way.
In this article we covered a handful of ways we can use to improve our use of memory and potentially render scenes that we previously was not able to.
Конфигурация операционной системы¶
- Увеличьте приоритет процесса Blender в вашей ОС.
- Увеличьте область подкачки, используемую ОС для подкачки памяти, также называемой размером файла подкачки виртуальной памяти, вплоть до размера вашей физической памяти.
- Используйте системный монитор для проверки того, что никакие другие процессы не используют значимое количество ресурсов процессора или оперативной памяти и закройте их в случае необходимости.
- Визуализация в фоновом режиме (из командной строки) сохранит немного дополнительной памяти.
Reduce memory usage by removing objects and geometry
Any object, vertex, edge or face we can remove is an element we don't need to load into memory.
In many projects we render a lot more objects than we need. For instance, in landscape scenes, we often keep a lot more landscape around that isn't in view of the camera.
Some of these objects may be needed because they contribute to reflections or shadows in the cameras view. But everything that isn't contributing can simply be removed.
We can also intelligently divide the scene into multiple render layers, rendering them separately and combine them again in the compositor. Just keep in mind that elements that has an influence on each other need to be rendered on the same layer.
Another example is if we are rendering a huge object, such as a skyscraper, castle or mountain, we could potentially remove geometry from the backside, only rendering the portion that actually face the camera.
If you are making multiple shots or animations, you can keep a major scene file that you copy and remove anything you don't need for that particular shot. Then do the same for each shot before finally editing them together in the VSE or an external video editor.
Reduce memory used by Blender by rendering from the command line
If we are still struggling to get our scene down in size, we can try to render from the command line. This way, we don't need the scene open in the interface while rendering, saving us memory during render time.
To render from the command line, on Windows, browse for your Blender installation folder from the command prompt and write the following command:
This will render the first frame in this blend file with the settings used from the blend file in question.
To render an animation, use the -a flag instead of -f. No parameter is needed.
How can we reduce memory used by geometry in Blender?
Our geometry uses a lot of RAM. When we experience problem with rendering thanks to the lack of RAM, reducing geometry is one of the most straight forward ways to improve the situation.
There are several ways we can reduce the amount of geometry in a Blender scene. Here are the ones we will cover.
- Managing subdivisions and multi-resolution
- Removing unnecessary objects and geometry
- Using and testing adaptive subdivision
- Using alt+d instead of shift+d when duplicating object.
Why does Blender crash during rendering?
The most common cause for Blender to not be able to complete a render is that it runs out of available RAM. This can be system RAM, or it can be your VRAM that is handled by your graphics card (GPU).
In most cases, if we have a dedicated graphics card, we can use it to render our scenes in Blender. Either with Cuda or Optix if we have an Nvidia card, or with OpenCL with AMD cards. If not, we can render with CPU.
No matter what compute device we choose to use, we still need to fit the data needed for rendering in the available RAM. If not, Blender crashes.
There are other reasons why Blender may crash during rendering, such as a bug in Blender or a graphics driver that isn't co-operating. If this is the case for you, you can read my article on common render problems to get some guidance on what driver to use for your graphics card.
These days, if we use a GPU to render, Blender can use both the GPUs VRAM and the system RAM when the VRAM becomes full. So, deciding between CPU and GPU based on the available VRAM and the size of a scene has become less of an issue.
However, we are still limited by the total amount of available memory and so Blender may still crash, so what can we do?
Многопроходный композитинг¶
Другой стратегией, которую можно использовать для решения проблемы длительной (повторной) визуализации, является структурирование с нуля вашего рабочего процесса, заключающееся в агрессивном использовании композитинга, который описан в разделе «Пост-обработка». При использовании этого подхода вы разбиваете каждую картинку на компоненты, которые могут быть визуализированы отдельно, а затем объединяете эти отдельно отрисованные элементы в готовый фильм. К примеру:
- If the camera is not moving, then neither is the background: only a single frame is needed. (The same is true of any non-moving object within the frame). These individual elements, having been generated once, can be reused as many times as necessary over as many frames as necessary.
- И тени, и блики могут быть захвачены отдельно от освещаемых или затеняемых объектов, поэтому их интенсивность, цвет и силу эффекта можно скорректировать позже без прибегания к повторной визуализации.
- Начните с использования источников света, не отбрасывающих тень (расчёты теней сильнее всего бьют по производительности). Затем используйте источники света «только с тенями» (которые отбрасывают тень, но не излучают свет) для создания теней только там, где вы думаете, что они действительно необходимы (очень часто бывает так, что лишь немногие из теней, которые могут существовать в сцене, нужны на самом деле, а остальные так и вообще просто незаметны).
- Запутанных ситуаций с освещением можно избежать, обрабатывая каждый объект отдельно от остальных, с последующим объединением фрагментов и «подправкой» результата.
Это очень знакомая идея. Например, в современной звукозаписи всегда используется «мульти-трековый» подход. Отдельные компоненты песни записываются отдельно и изолированно, а затем «сводятся» вместе. «Окончательное сведение» затем проходит через этапы дополнительной обработки, называемой мастеринг, для производства готового продукта (на самом деле, возможности и дизайн современного программного обеспечения для обработки звука прямо аналогичны «узловому» композитору Blender’а).
У такого подхода есть убедительные преимущества:
- If something is «not quite right», you do not necessarily have to start over from scratch.
- In practice, the deadline-killer is re-rendering, which ordinarily must be done (in its entirety) just because «„one little thing“ about the shot is wrong». Compositing helps to avoid this, because (ideally…) only the specific parts that are found to be in error must be repeated (or, maybe, the error can be blocked out with a «garbage matte» and a corrected version can be inserted in its place).
- Sometimes you might find that it is almost what you wanted, but now you would like to add this and maybe take away that. A compositing-based approach enables you to do just that, and furthermore, to do so non-destructively. In other words, having generated the «addition» (or the «mask») as a separate channel of information, you can now fine-tune its influence in the overall «mix», or even change your mind and remove it altogether, all without permanently altering anything.
- By and large, these stages work two-dimensionally, manipulating what is by that time «a raster bitmap with R, G, B, Alpha and Z-depth information», so they are consistently fast.
- Поскольку каждая отдельная задача визуализации была упрощена, компьютер может выполнять их, используя гораздо меньше ресурсов.
- Задачи могут быть распределены среди нескольких разных компьютеров.
- «After all, the scene does not actually have to be physically perfect, to be convincing». A compositing-based approach lets you take full advantage of this. You can focus your attention (and Blender’s) upon those specific aspects of the scene which will actually make a noticeable difference. It is possible to save a considerable amount of time by consciously choosing to exclude less-important aspects which (although «technically correct») probably will not be noticed.
Of course, this approach is not without its own set of trade-offs. You must devise a workable asset management system for keeping track of exactly what material you have, where it is, whether it is up-to-date, and exactly how to re-create it. You must understand and use the «library linking» features of Blender to allow you to refer to objects, nodes, materials, textures and scenes in a carefully-organized collection of other files. You need to have a very clear notion, in advance, of exactly what the finished shot must consist of and what the task breakdown must be. You must be a scrupulous note-taker and record-keeper. But sometimes this is the best way, if not the only way, to accomplish a substantial production.
Owen Jefferson запись закреплена
Owen, лучше скажи, какая видеокарта и сколько опратиной памяти на компе. Бегство из одной секты в другую не спасёт.
Alexander, jajaja. А если серьёзно, то с этим постом я тоже задумался, почему гиговой видеокарты не хватает на сцену в 500-600 мбайт. Уже запустил системник с 560ti и тестирую.
Итак, что мы имеем.
1) При рендеринге на ЦПУ вся сцена обрабатывается целиком в RAM, не выходя на внешние устройства и не загружая никаких PCI-шин. Рендеринг стабильный, безотказный и, в большинсте случаев медленный. В случае нехватки памяти система банально зависает, но масштабировать такую систему гораздо легче.
2) При рендеринге на ГПУ сцена дублируется из RAM в видеопамять и обратно. Со стороны CUDA приходит инициатива на создание адресного пространства, со стороны CPU происходит передача полномочий. Поскольку сцена продублирована, кол-во оперативной памяти не уменьшается. Обмен данными происходит по шине PCI-E, у которой тоже есть свои лимиты. Что это значит? Это значит, что:
А) При нехватке оперативной памяти CUDA получает отказ на создание адресного пространства. Результат предсказуем: "CUDA Error: Out of Memory".
Б) При нехватке видеопамяти сцена не может загрузиться в видеобуфер для дальнейшего обсчёта. Аналогично: "CUDA Error: Out of Memory".
В) При недостаточной пропускной способности PCI-e шины мы имеет ошибку вида "Unknown error in cuCtxSynchronise(). Встречается данный тип ошибок редко в связи с широкой распространённостью шины PCI-E x16 2.0/3.0.
Owen, у тебя сцена на почти 4 миллиона полигонов, там куда больше, чем 500 мбайт. Потому двухгиговая 750ti и не тянет. Реж-дели на слои. Можешь ещё глянуть Light paths: там можно уменьшить аппетиты в рассчёте света.
Всем привет!
Пока работаешь в object mode все прекрасно, все действия проходят без единой задержки. Но стоит включить в edit mode начинаются страшные тормоза. На то, чтобы выделить, сдеформировать или выполнить любое другое действие приходится ждать по 5 - 25 минут.
Моделька состоит из 2000000 вершин.
И вот что странно, при этом все ресурсы компа не задействованы и на 20%.
Уже перечитал кучу статей, форумов, прошелся, наверно, по всем настройкам. Но решения не нашел.
blender-2.77a windows 7 64
i7-6700K
GeForce GTX 1070
Оперативка 32 гига
Может, кто с этим сталкивался. Посоветуйте пожалуйста, что можно тут сделать.
>Моделька состоит из 2000000 вершин.
>windows 7
>выполнить любое другое действие приходится ждать по 5 - 25 минут.
Хахаха! но все-таки хочется "вылечить" это.
Алексей, да легко! У меня на кубунте 14.04 на конфиге в разы слабее лаги всего в районе минуты-двух ;)
Максим, спасибо, все понятно.
Блендер тормозит, при редактировании многополигональных файлов. При этом комп не загружен - значит блендер просто не использует ресурсы компа. Вопрос: ПОЧЕМУ?
Не хватает каких-то дров?
Или не включена какая-то функция?
или причина в третьем.
Может кто-то, что-то знает об этом? Пожалуйста поделитесь опытом.
у меня видюха квадра и всё еще показательнее, у меня уже после 100к полигонов в режиме вершин наблюдаются подлагивания, а при скульптинге хоть 2 ляма пофиг. это явно что то в разногласиях опенджиэля и энвидии
В основном, все организации связанные с проектами графики, работают на Linux Debian. Чего и Вам советую опробовать. Под Windows-ом есть проблемы.
у меня ведюха 1060 и 8 гб оперативки. процеццос i3 8100 ну или как то так, и очень часто когда редактирую много объектов, типо как волосы, у меня просто дико лагает блендер, драйвера все обновил, думаю может видюха и процессор просто не задействуются? подскажите что это может быть, читал что там какието DX11 надо устанавливать, ну или чо то типо того, подскажите что мне сделать.у меня это происходит так! я делаю какое либо действие, потом у меня дико лагает блендер, при этом нельзя убирать курсор с рабочего места, ну к примеру когда я хочу причесать волосы(частицы) начинаю, у меня дико лагает блендер, то есть прям жуть, и через 7-8 секунд проходят лаги. что делать?
Алексей, у меня ведюха 1060 и 8 гб оперативки. процеццос i3 8100 ну или как то так, и очень часто когда редактирую много объектов, типо как волосы, у меня просто дико лагает блендер, драйвера все обновил, думаю может видюха и процессор просто не задействуются? подскажите что это может быть, читал что там какието DX11 надо устанавливать, ну или чо то типо того, подскажите что мне сделать.у меня это происходит так! я делаю какое либо действие, потом у меня дико лагает блендер, при этом нельзя убирать курсор с рабочего места, ну к примеру когда я хочу причесать волосы(частицы) начинаю, у меня дико лагает блендер, то есть прям жуть, и через 7-8 секунд проходят лаги. что делать?
Александр, На данный момент тебе можно поставить высокий приоритет блендера в системе.
8 гб оперативки это минимум, для комфортной работы нужно 16.
При переполнении оперативки, естественно пойдут лаги, и бледер может слететь.
Мощность видеокарты нужна только для рендера.
В остальном же, дело в вычислительной мощности процессора. В режиме редактирования, для того чтобы проц успевал рассчитать всю геометрию модели нужна высокая частота. И опять же, если кеш L3 будет маленьким, то проц будет просто простаивать. Нужно учитывать, что проц в любом случает не будет загружаться на 100%. Ибо режим редактирования не может работать в мульти потоке. Полностью нагружается только одно ядро.
Можно разогнать проц, но дальше кеш L3 будет потолком.
Мощное железо это, конечно, очень хорошо, но иногда может и не стоит на него особо тратиться.
Для меня решением стало изменение подхода к моделированию. Просто стоит изучить модификаторы, там и решения поставленных задач найдутся
Если вас это успокоит, то 3dsMax также тормозит. Видимо не рассчитан этот софт на одновременное редактирование таких массивов. Ну я по старой советской привычке стараюсь не доводить количество полигонов до 1-2 миллионов на всю сцену.
Может все таки кто то нашел решение проблемы, у меня ryzen 9 5900hx и rtx3060, 16 гигов оперативы. И blender постоянно лагает в Эдит моде или при использовании каких то тяжелых модификаторов, при этом использует он всего 8% процентов от мощности процессора и всего 2 гига оперативы. Ну это же явно не норм, я специально покупал ноутбук для работы мощный. Ноутбучных процессоров ещё мощнее сейчас просто нет на рынке, да и смысл если blender просто тупо не использует ресурсы компьютера.
Павел, интересно конечно, может просто у вас какие-то ограничения стоят по производительности в настройках питания? так-то у вас не комп , а зверь, мне бы его на месяцок на стол я бы все игрушки прошёл и вам вернул))) хотя мой на 4600h amd ryzen тоже тянет все, но не все на максах уже
Ростислав Глянь запись закреплена
Ну так да, больше 4гб не поставишь. Но оно все равно юзает больше 4гигов( можешь мониторинг включить и посмотреть)
Кирилл, просто у меня начинает дико фризить при включённом браузере, а если ещё и запустить видос на бг, то смэрть
Вячеслав Епифанов
Вячеслав Епифанов ответил Кириллу
Оптимизация производительности визуализации¶
«Кто над чайником стоит, у того он не кипит» – старая поговорка, но вы можете задаться вопросом, почему визуализация занимает так много времени до своего завершения, или ещё того хуже, падает на половине пути! Ну, во время визуализации происходит много вещей и большинство из них вы можете ускорить, либо включить в сложную визуализацию, чтобы дождаться её завершения. Кроме того, можно отрисовать очень сложную сцену на посредственном ПК, если проявить некоторую смекалку. Вот список вещей из «горячей десятки», которые следует или не следует делать, чтобы ускорить визуализацию или избежать падения во время визуализации. Некоторые параметры могут снизить качество визуализации, но в случае с черновыми визуализациями вы можете не беспокоиться об этом.
How can we free up memory used by other applications?
The last option we will explore is simply to make sure that the system uses as little ram as possible elsewhere. We can do this by opening the task manager on Windows with Ctrl+Alt+Delete or Ctrl+Shift+ESC.
Sort your open applications by memory usage and see what software is using up the most RAM. Blender is likely one of them. If there are others like your web browser or other open applications, you can close them to free up memory during rendering.
How can we reduce memory used by materials and textures in Blender?
Here we have two options. Removing textures that are not needed or use a lower resolution texture if possible. We will start by looking at ways we can remove certain texture types and replace them with something else. Then we will look at a few ways to quickly manage texture sizes.
When working with PBR materials we most often have these texture maps:
- Diffuse/Albedo
- Roughness
- Normal
- Metalness
The easiest image texture to remove is the roughness. But this map is also the most creative map so, depending on how we use it we may or may not have an easy time removing it to save memory.
For instance, if we are using overlays with the roughness and play of light is a big part of our scene, we may just not want to replace it.
In many cases though we can use one of the red, green, or blue channels of the diffuse texture instead of a separate image texture map for roughness.
This is what it could look like.
In this case we get a pattern that matches the diffuse texture while not losing much of the original roughness texture. This is also a very rough surface to begin with, just like most surfaces we encounter.
In these cases we rarely see a difference between an accurate roughness map and this method.
Sometimes we can also replace the normal map with a bump node with input from the diffuse texture or one of the single channels as well. But in general, we get a much finer and more even detail with this method than a normal map. So the method is much more limited.
This is how to set it up.
For instance, if this surface was covered with grass, this may be enough to give us a realistic enough ground plane.
The second way we can reduce memory used by a material is to use lower resolution textures. Simply bring your image texture into a 2D photo image editor like photoshop, affinity photo or gimp and reduce the size.
Computers store data in increments to the power of two. So, the most efficient textures to store are sizes like 512, 1024, 2048 4096 and so on.
A texture with the size of 2048 by 2048 takes only a quarter of the memory compared to a 4096 by 4096 texture.
We can also reduce the size of all textures in Blender simultaneously by using the simplify options. We cover this later in this article.
Link instead of duplicating data with Alt+D
Very often we are taught that to duplicate an object, use Shift+D. This command duplicates both the object and the mesh, making a completely new copy in memory.
If we intend to not change the duplicate, but keep it just as the original, we can save a lot of memory by using alt+d to link the data instead.
With alt+d we create a new object, but we let it point to the original mesh data inside the original object. Now we have two objects that look the same with minimal RAM footprint.
What can we do when Blender run out of memory during rendering?
From a birds-eye view there are two things we can do. We can free up more memory and we can reduce the amount of memory used by Blender during rendering.
In many cases, we start in the second category. By reducing memory used in a scene. This is usually where we can gain most because many scenes are overwhelmingly unoptimized.
Here is a list of the primary things that can have a significant impact in reducing memory usage for our scenes.
- Geometry amount and density
- Number of textures and their sizes
- If using particle systems, the number of particles and use of child particles
Some settings and features that has little to no memory impact on the other hand are things like number of light paths and samples. Also, the tile size is something that gets brought up as optimizations.
These are all valuable settings when we want to optimize the use of the CPU and GPU and improve render time. But they have almost no impact on memory usage.
We must distinguish between feature that impact memory vs CPU or GPU computations.
Let's look at each of the primary ways to reduce memory used by our scene before we move on to how we can free up memory for use in the scene in other areas.
Читайте также: