void ON_Layer::Dump( ON_TextLog& dump ) const { const wchar_t* sName = LayerName(); if ( !sName ) sName = L""; dump.Print("index = %d\n",m_layer_index); dump.Print("name = \"%S\"\n",sName); dump.Print("display = %s\n",m_bVisible?"visible":"hidden"); dump.Print("picking = %s\n",m_bLocked?"locked":"unlocked"); dump.Print("display color rgb = "); dump.PrintRGB(m_color); dump.Print("\n"); dump.Print("plot color rgb = "); dump.PrintRGB(m_plot_color); dump.Print("\n"); dump.Print("default material index = %d\n",m_material_index); }
void ON_Light::Dump( ON_TextLog& dump ) const { ON_BOOL32 bDumpDir = false; ON_BOOL32 bDumpLength = false; ON_BOOL32 bDumpWidth = false; const char* sStyle = "unknown"; switch(Style()) { //case ON::view_directional_light: // sStyle = "view_directional_light"; // bDumpDir = true; // break; //case ON::view_point_light: // sStyle = "view_point_light"; // break; //case ON::view_spot_light: // sStyle = "view_spot_light"; // bDumpDir = true; // break; case ON::camera_directional_light: sStyle = "camera_directional_light"; bDumpDir = true; break; case ON::camera_point_light: sStyle = "camera_point_light"; break; case ON::camera_spot_light: sStyle = "camera_spot_light"; bDumpDir = true; break; case ON::world_directional_light: sStyle = "world_directional_light"; bDumpDir = true; break; case ON::world_point_light: sStyle = "world_point_light"; break; case ON::world_spot_light: sStyle = "world_spot_light"; bDumpDir = true; break; case ON::world_linear_light: sStyle = "linear_light"; bDumpDir = true; bDumpLength = true; break; case ON::world_rectangular_light: sStyle = "rectangular_light"; bDumpDir = true; bDumpLength = true; bDumpWidth = true; break; case ON::ambient_light: sStyle = "ambient_light"; break; case ON::unknown_light_style: sStyle = "unknown"; break; default: sStyle = "unknown"; break; } dump.Print("index = %d style = %s\n",LightIndex(),sStyle); dump.Print("location = "); dump.Print(Location()); dump.Print("\n"); if ( bDumpDir ) dump.Print("direction = "); dump.Print(Direction()); dump.Print("\n"); if ( bDumpLength ) dump.Print("length = "); dump.Print(Length()); dump.Print("\n"); if ( bDumpWidth ) dump.Print("width = "); dump.Print(Width()); dump.Print("\n"); dump.Print("intensity = %g%%\n",Intensity()*100.0); dump.Print("ambient rgb = "); dump.PrintRGB(Ambient()); dump.Print("\n"); dump.Print("diffuse rgb = "); dump.PrintRGB(Diffuse()); dump.Print("\n"); dump.Print("specular rgb = "); dump.PrintRGB(Specular()); dump.Print("\n"); dump.Print("spot angle = %g degrees\n",SpotAngleDegrees()); }