- scm_c_bind_keyword_arguments
- ("make-material", rest, (scm_t_keyword_arguments_flags)0,
- scm_from_utf8_keyword ("material-type"), &material_type,
- scm_from_utf8_keyword ("ambient-color"), &ambient_color,
- scm_from_utf8_keyword ("diffuse-color"), &diffuse_color,
- scm_from_utf8_keyword ("emissive-color"), &emissive_color,
- scm_from_utf8_keyword ("specular-color"), &specular_color,
- scm_from_utf8_keyword ("shininess"), &shininess,
- scm_from_utf8_keyword ("material-type-param"), &material_type_param,
- scm_from_utf8_keyword ("material-type-param-2"), &material_type_param_2,
- scm_from_utf8_keyword ("thickness"), &thickness,
- scm_from_utf8_keyword ("z-buffer"), &z_buffer,
- scm_from_utf8_keyword ("anti-aliasing"), &anti_aliasing,
- scm_from_utf8_keyword ("color-mask"), &color_mask,
- scm_from_utf8_keyword ("color-material"), &color_material,
- scm_from_utf8_keyword ("blend-operation"), &blend_operation,
- scm_from_utf8_keyword ("polygon-offset-factor"), &polygon_offset_factor,
- scm_from_utf8_keyword ("polygon-offset-direction"), &polygon_offset_direction,
- scm_from_utf8_keyword ("wireframe"), &wireframe,
- scm_from_utf8_keyword ("point-cloud"), &point_cloud,
- scm_from_utf8_keyword ("gouraud-shading"), &gouraud_shading,
- scm_from_utf8_keyword ("lighting"), &lighting,
- scm_from_utf8_keyword ("z-write-enable"), &z_write_enable,
- scm_from_utf8_keyword ("backface-culling"), &backface_culling,
- scm_from_utf8_keyword ("frontface-culling"), &frontface_culling,
- scm_from_utf8_keyword ("fog-enable"), &fog_enable,
- scm_from_utf8_keyword ("normalize-normals"), &normalize_normals,
- scm_from_utf8_keyword ("use-mip-maps"), &use_mip_maps,
- SCM_UNDEFINED);
+video::E_ANTI_ALIASING_MODE
+scm_to_anti_aliasing_mode (SCM anti_aliasing_mode)
+{
+ char* mode = scm_to_utf8_stringn (scm_symbol_to_string (anti_aliasing_mode), NULL);
+ if (!strcmp (mode, "off"))
+ {
+ return video::EAAM_OFF;
+ }
+ else if (!strcmp (mode, "simple"))
+ {
+ return video::EAAM_SIMPLE;
+ }
+ else if (!strcmp (mode, "quality"))
+ {
+ return video::EAAM_QUALITY;
+ }
+ else if (!strcmp (mode, "line-smooth"))
+ {
+ return video::EAAM_LINE_SMOOTH;
+ }
+ else if (!strcmp (mode, "point-smooth"))
+ {
+ return video::EAAM_POINT_SMOOTH;
+ }
+ else if (!strcmp (mode, "full-basic"))
+ {
+ return video::EAAM_FULL_BASIC;
+ }
+ else if (!strcmp (mode, "alpha-to-coverage"))
+ {
+ return video::EAAM_ALPHA_TO_COVERAGE;
+ }
+ else
+ {
+ scm_error (scm_arg_type_key, NULL, "Wrong anti aliasing mode: ~S",
+ scm_list_1 (anti_aliasing_mode), scm_list_1 (anti_aliasing_mode));
+ }
+}