Create parsing system that converts supported nodes and ignores unsupported #2

Merged
Bogdan Nagirniak merged 14 commits from Vasyl-Pidhirskyi/blender:BLEN-500 into matx-export-material 2023-08-28 12:29:46 +02:00
Collaborator

Added get_mx_type method to get relevant MaterialX socket type.
Added get_input_link_node to convert the next linked node.
Improved export_to_materialx method so we can see MaterialX result with Storm delegate.

Initial implementation based on #1 for convenient review and debugging.
Added export to MaterialX file, currently hardcoded and needs to be removed.
Added hardcoded path to Image (needs to be removed) as far as this part is ignored.

#ifdef WITH_HYDRA
  image_path = cache_or_get_image_file(bmain, scene, image, &tex->iuser);
#endif
Added `get_mx_type method` to get relevant MaterialX socket type. Added `get_input_link_node` to convert the next linked node. Improved `export_to_materialx` method so we can see MaterialX result with Storm delegate. Initial implementation based on #1 for convenient review and debugging. Added export to MaterialX file, currently hardcoded and needs to be removed. Added hardcoded path to Image (needs to be removed) as far as this part is ignored. ``` #ifdef WITH_HYDRA image_path = cache_or_get_image_file(bmain, scene, image, &tex->iuser); #endif ```
Vasyl Pidhirskyi added 3 commits 2023-08-23 09:49:41 +02:00
Vasyl Pidhirskyi reviewed 2023-08-23 09:50:24 +02:00
@ -33,1 +47,4 @@
}
MaterialX::writeToXmlFile(
doc,
MaterialX::FilePath("c:/Users/Vasyl_Pidhirskyi/Work/AMD/blender-git/tmp/material.mtlx"));
Author
Collaborator

this needs to be removed

this needs to be removed
BogdanNagirniak marked this conversation as resolved
Vasyl Pidhirskyi reviewed 2023-08-23 09:50:55 +02:00
@ -0,0 +26,4 @@
const NodeTexImage *tex = static_cast<NodeTexImage *>(node->storage);
Scene *scene = DEG_get_input_scene(depsgraph);
Main *bmain = DEG_get_bmain(depsgraph);
std::string image_path = "C:/Users/Vasyl_Pidhirskyi/Desktop/Untitled.png";
Author
Collaborator

this needs to be removed

this needs to be removed
BogdanNagirniak marked this conversation as resolved
Georgiy Markelov was assigned by Vasyl Pidhirskyi 2023-08-23 11:10:24 +02:00
Bogdan Nagirniak was assigned by Vasyl Pidhirskyi 2023-08-23 11:10:25 +02:00
Vasyl Pidhirskyi requested review from Bogdan Nagirniak 2023-08-23 11:10:31 +02:00
Bogdan Nagirniak added 4 commits 2023-08-24 16:10:17 +02:00
Bogdan Nagirniak added 1 commit 2023-08-25 14:17:10 +02:00
Bogdan Nagirniak added 1 commit 2023-08-25 15:08:01 +02:00
Bogdan Nagirniak added 2 commits 2023-08-26 01:20:38 +02:00
Bogdan Nagirniak added 1 commit 2023-08-26 03:43:52 +02:00
Bogdan Nagirniak added 1 commit 2023-08-26 10:19:10 +02:00
Bogdan Nagirniak approved these changes 2023-08-26 13:11:28 +02:00
Bogdan Nagirniak left a comment
Collaborator

Finished this task, implemented node export system: created class NodeParser and class NodeItem

Finished this task, implemented node export system: created `class NodeParser` and `class NodeItem`
Bogdan Nagirniak changed title from WIP: Create parsing system that converts supported nodes and ignores unsupported to Create parsing system that converts supported nodes and ignores unsupported 2023-08-26 13:11:35 +02:00
Georgiy Markelov approved these changes 2023-08-28 12:17:49 +02:00
Georgiy Markelov left a comment
Owner

Tested, works fine.

Tested, works fine.
Bogdan Nagirniak added 1 commit 2023-08-28 12:26:59 +02:00
Bogdan Nagirniak merged commit c5b48921bf into matx-export-material 2023-08-28 12:29:46 +02:00
Sign in to join this conversation.
No Label
No Milestone
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: DagerD/blender#2
No description provided.