Page MenuHomePhorge

Material.proto
No OneTemporary

Size
5 KB
Referenced Files
None
Subscribers
None

Material.proto

syntax = "proto2";
package Echo.Resources;
message Material
{
message Colour
{
optional float r=1 [default=1.0];
optional float g=2 [default=1.0];
optional float b=3 [default=1.0];
optional float a=4 [default=1.0];
optional string s=5 [default="#FFFFFFFF"];
}
message BlendMode
{
enum BlendModeEnum
{
NONE=0;
TRANSPARENT=1;
ADDITIVE=2;
ADDITIVE_COLOUR=3;
//These are additional presets for texture units.
MODULATE=4;
MODULATE_AND_BRIGHTEN=5;
MODULATE_AND_BRIGHTEN_MORE=6;
SUBTRACT=7;
}
}
message MemoryMode
{
enum MemoryModeEnum
{
NONE=0; // Use the system configured mode.
FAST_RELOAD=1; // Attempts to enable fast resource reload at the cost of higher memory usage.
LOW_MEMORY=2; // Attempts to reduce the memory usage by reloading resources from the original source, at the cost of slower reload.
}
}
message Blend
{
message BlendSource
{
enum BlendSourceEnum
{
CURRENT=0;
TEXTURE=1;
DIFFUSE=2;
SPECULAR=3;
MANUAL=4;
}
}
message BlendOperation
{
enum BlendOperationEnum
{
ADD=0;
ADD_SIGNED=1;
ADD_SMOOTH=2;
MODULATE=3;
MODULATE_X2=4;
MODULATE_X4=5;
SUBTRACT=6;
SOURCE1=7;
SOURCE2=8;
BLEND_DIFFUSE_ALPHA=9;
BLEND_TEXTURE_ALPHA=10;
BLEND_CURRENT_ALPHA=11;
BLEND_DIFFUSE_COLOUR=12;
MANUAL=13;
BLEND_DOT_PRODUCT=14;
}
}
optional BlendSource.BlendSourceEnum source1=2;
optional BlendSource.BlendSourceEnum source2=3;
required BlendOperation.BlendOperationEnum operation=4;
}
message TextureWrapMode
{
enum TextureWrapModeEnum
{
CLAMP=0;
CLAMP_TO_EDGE=1;
REPEAT=2;
}
}
message TextureFilter
{
enum TextureFilterEnum
{
NEAREST=0;
LINEAR=1;
}
}
message TextureGeneration
{
message Plane
{
required float a=1;
required float b=2;
required float c=3;
required float d=4;
}
message CubeMap
{
required string pos_x=1;
required string pos_y=2;
required string pos_z=3;
required string neg_x=4;
required string neg_y=5;
required string neg_z=6;
}
enum TextureGenerationModeEnum
{
NONE=0;
LINEAR=1;
EYE_LINEAR=2;
SPHERE=3;
CUBE=4;
}
required TextureGenerationModeEnum mode=1;
optional Plane q_plane=2;
optional Plane r_plane=3;
optional Plane s_plane=4;
optional Plane t_plane=5;
optional CubeMap cube_map=6;
}
message DepthFunction
{
enum DepthFunctionEnum
{
NEVER=0;
LESS=1;
EQUAL=2;
LESS_OR_EQUAL=3;
GREATER=4;
NOT_EQUAL=5;
GREATER_OR_EQUAL=6;
ALWAYS=7;
}
}
message AlphaTestFunction
{
enum AlphaTestFunctionEnum
{
NEVER=0;
LESS=1;
EQUAL=2;
LESS_OR_EQUAL=3;
GREATER=4;
NOT_EQUAL=5;
GREATER_OR_EQUAL=6;
ALWAYS=7;
}
}
message CullMode
{
enum CullModeEnum
{
NONE=0;
FRONT=1;
BACK=2;
}
}
message StripFrame
{
required float u=1;
required float v=2;
required float frame_time=3;
}
message AutoStripAnimation
{
required uint32 start_frame=1;
required uint32 frame_count=2;
required float frame_width_percent=3;
required float frame_height_percent=4;
required float frame_time=5;
}
message StripAnimation
{
repeated StripFrame frame=1;
optional bool loop=2;
optional bool randomise=3;
optional bool use_transform=4;
optional AutoStripAnimation auto_frames=5;
}
message CubeMap
{
required string name=1;
optional string front=2;
optional string back=3;
optional string left=4;
optional string right=5;
optional string top=6;
optional string bottom=7;
}
message TextureUnit
{
optional BlendMode.BlendModeEnum blend_mode=1;
optional TextureWrapMode.TextureWrapModeEnum wrap_u=2;
optional TextureWrapMode.TextureWrapModeEnum wrap_v=3;
optional TextureFilter.TextureFilterEnum min_filter=4;
optional TextureFilter.TextureFilterEnum mag_filter=5;
optional string image=6;
optional TextureGeneration tex_gen=7;
optional float u_scroll=8;
optional float v_scroll=9;
optional float u_scale=10;
optional float v_scale=11;
optional float x_rot=12;
optional float y_rot=13;
optional float z_rot=14;
optional StripAnimation strip_animation=15;
optional Blend alpha_blend=16;
optional Blend colour_blend=17;
optional MemoryMode.MemoryModeEnum memory_mode=18;
optional uint32 texture_coordinate_set=19;
optional Colour manual_colour=20;
optional CubeMap cubemap=21;
}
message ShaderProgram
{
repeated string geometry_shader=1;
repeated string vertex_shader=2;
repeated string fragment_shader=3;
repeated string variable=4;
optional string matrix_variable=5;
optional string camera_position_variable=6;
optional string world_matrix=7;
optional string view_matrix=8;
optional string projection_matrix=9;
}
message Pass
{
optional BlendMode.BlendModeEnum blend_mode=1;
optional DepthFunction.DepthFunctionEnum depth_function=2;
optional CullMode.CullModeEnum cull_mode=3;
optional bool lighting=4;
optional bool depth_write=5;
optional bool depth_check=6;
optional Colour ambient=7;
optional Colour diffuse=8;
optional Colour specular=9;
optional Colour emissive=10;
optional float shininess=11;
repeated TextureUnit texture_unit=12;
optional bool vertex_colour=13;
optional bool active=14;
optional ShaderProgram program=15;
optional AlphaTestFunction.AlphaTestFunctionEnum alpha_test_function=16;
optional float alpha_test_value=17;
optional float point_and_line_size=18;
}
repeated Pass pass=1;
optional string name=2;
}
message Materials
{
repeated Material material = 1;
}

File Metadata

Mime Type
text/plain
Expires
Wed, Jan 15, 10:38 PM (10 h, 53 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
72072
Default Alt Text
Material.proto (5 KB)

Event Timeline