# How to read illum value from mtl file using Assimp library?

I am loading an OBJ file using the ASSIMP library. Following is the MTL file associated with the obj file.

newmtl initialShadingGroup
Kd 0.50 0.50 0.50
Ka 0.09 0.09 0.09
Tf 1.00 1.00 1.00
Ns 10.0
map_Ka sphere_roughness.jpg
map_Kd sphere_albedo.jpg
map_Ks sphere_metallic.jpg
bump sphere_normal.jpg
disp sphere_bump.jpg
illum 7


I want to read the illum value so that I can choose an appropriate sharding model in my shaders. The code I'm using is

int shadingModel;


But the output I'm getting is

ShadingModel: 2


when the value is 7. Is there something that I'm doing it wrong or is it the wrong way to retrieve the shading model. Thanks for your help!

According to the source (https://github.com/assimp/assimp/blob/b7df376836e36c4b6998ce95d97626e30f61c2f0/code/AssetLib/Obj/ObjFileImporter.cpp#L594) only illum values of 0, 1, 2 are supported:

    // convert illumination model
int sm = 0;
switch (pCurrentMaterial->illumination_model) {
case 0: