Class: Sketchup::Texture
Overview
The Texture class contains methods for obtaining information about textures that are part of your materials in your model (within the In-Model section of the Materials Browser). Remember, textures are repeatable images that “tile” when painted on a surface.
Instance Method Summary collapse
-
#average_color ⇒ Object
The average_color method retrieves a color object with the average color found in the texture.
-
#filename ⇒ Object
The filename method retrieves the entire path, including the file, for a texture object.
-
#height ⇒ Object
The height method is used to get the height of a repeatable texture image, in inches.
-
#image_height ⇒ Object
The image_height method retrieves the height of the repeatable texture image, in pixels.
-
#image_width ⇒ Object
The image_width method retrieves the width of the repeatable texture image, in pixels.
-
#size=(size) ⇒ Object
The size= method allows you to set the size of the repeatable texture image, in inches,.
-
#valid? ⇒ Object
The valid? method ensures that a texture is valid.
-
#width ⇒ Object
The width method is used to get the width of a repeatable texture image, in inches.
-
#write(filename, colorize = false) ⇒ Object
Writes the texture to file with option to preserve the color adjustments made by the material.
Methods inherited from Entity
#add_observer, #attribute_dictionaries, #attribute_dictionary, #delete_attribute, #deleted?, #entityID, #get_attribute, #inspect, #model, #parent, #persistent_id, #remove_observer, #set_attribute, #to_s, #typename
Instance Method Details
#average_color ⇒ Object
The average_color method retrieves a color object with the average color found in the texture.
#filename ⇒ Object
The filename method retrieves the entire path, including the file, for a texture object.
#height ⇒ Object
The height method is used to get the height of a repeatable texture image, in inches.
#image_height ⇒ Object
The image_height method retrieves the height of the repeatable texture image, in pixels.
#image_width ⇒ Object
The image_width method retrieves the width of the repeatable texture image, in pixels.
#size=(size) ⇒ Object
The size= method allows you to set the size of the repeatable texture image, in inches,
#valid? ⇒ Object
The valid? method ensures that a texture is valid.
#width ⇒ Object
The width method is used to get the width of a repeatable texture image, in inches.
#write(filename, colorize = false) ⇒ Object
Writes the texture to file with option to preserve the color adjustments made by the material.