Logo
MaterialInfo.h
1#pragma once
2#include "gfx/mdl/materialInfo.h"
3
4namespace SharpKmyGfx
5{
6 public ref class MaterialInfo
7 {
8 kmyGfx::mtlInfo* obj = nullptr;
9
10 System::String^ convert(const char* ptr)
11 {
12 if (*ptr == '\0')return nullptr;
13
15 }
16
17 public:
18 MaterialInfo(kmyGfx::mtlInfo* base)
19 {
20 obj = base;
21 }
22
23 //TODO 200820 文字コードを考慮したい
24 System::String^ getName()
25 {
26 return convert(obj->m_name.cstr());
27 }
28
29 System::String^ getDiffuseTextureName()
30 {
31 return convert(obj->m_diffuseTextureName.cstr());
32 }
33
34 System::String^ getAmbientTextureName()
35 {
36 return convert(obj->m_ambientTextureName.cstr());
37 }
38
39 System::String^ getEmissionTextureName()
40 {
41 return convert(obj->m_emissionTextureName.cstr());
42 }
43
44 System::String^ getNormalTextureName()
45 {
46 return convert(obj->m_normalTextureName.cstr());
47 }
48
49 System::String^ getSpecularTextureName()
50 {
51 return convert(obj->m_specularTextureName.cstr());
52 }
53 };
54
55}
static String New(std::string s)
Definition: SharpKmyCore.cpp:78
Definition: MaterialInfo.h:7
System::String getEmissionTextureName()
Definition: MaterialInfo.h:39
System::String getDiffuseTextureName()
Definition: MaterialInfo.h:29
System::String convert(const char *ptr)
Definition: MaterialInfo.h:10
System::String getSpecularTextureName()
Definition: MaterialInfo.h:49
System::String getName()
Definition: MaterialInfo.h:24
kmyGfx::mtlInfo * obj
Definition: MaterialInfo.h:8
System::String getNormalTextureName()
Definition: MaterialInfo.h:44
MaterialInfo(kmyGfx::mtlInfo *base)
Definition: MaterialInfo.h:18
System::String getAmbientTextureName()
Definition: MaterialInfo.h:34
Definition: Asset.h:4