local my_path = LockOn_Options.script_path.."PCN/"
dofile(my_path.."PCN_definitions.lua")

local half_width   = GetScale()
local half_height  = GetAspect() * half_width
local aspect       = GetAspect() -- GetHalfHeight()/GetHalfWidth()

pcn_br_base					= CreateElement "ceMeshPoly" -- untextured shape
pcn_br_base.name			= "PCN_BR"
pcn_br_base.material		= MakeMaterial(nil,{255,0,0,50})
pcn_br_base.h_clip_relation	= h_clip_relations.REWRITE_LEVEL
pcn_br_base.level			= PCN_DEFAULT_LEVEL
pcn_br_base.collimated		= false
pcn_br_base.isvisible		= false
pcn_br_base.z_emable		= true
pcn_br_base.vertices		= { {-1, aspect}, { 1,aspect}, { 1,-aspect}, {-1,-aspect}, }
pcn_br_base.indices			=  {0,1,2 ;  0,2,3 }
Add(pcn_br_base)


-- ** LEFT LCD ** --
add_layer("PCN_BL_SEG0",    {-0.20, 0.06},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BL_SEG", 0}})
add_layer("PCN_BL_SEG1",    {-0.20, 0.06},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BL_SEG", 1}})
add_layer("PCN_BL_SEG2",    {-0.20, 0.06},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BL_SEG", 2}})
add_layer("PCN_BL_SEG3",    {-0.20, 0.06},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BL_SEG", 3}})
add_layer("PCN_BL_SEG4",    {-0.20, 0.06},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BL_SEG", 4}})
add_layer("PCN_BL_SEG5",    {-0.20, 0.06},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BL_SEG", 5}})
add_layer("PCN_BL_SEG6",    {-0.20, 0.06},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BL_SEG", 6}})

-- ** RIGHT LCD ** --+
add_layer("PCN_BR_SEG0",    { 1.00, 0.07},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BR_SEG", 0}})
add_layer("PCN_BR_SEG1",    { 1.00, 0.07},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BR_SEG", 1}})
add_layer("PCN_BR_SEG2",    { 1.00, 0.07},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BR_SEG", 2}})
add_layer("PCN_BR_SEG3",    { 1.00, 0.07},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BR_SEG", 3}})
add_layer("PCN_BR_SEG4",    { 1.00, 0.07},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BR_SEG", 4}})
add_layer("PCN_BR_SEG5",    { 1.00, 0.07},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BR_SEG", 5}})
add_layer("PCN_BR_SEG6",    { 1.00, 0.07},     "RightCenter",  "88",   pcn_font_size_default,    {{"PCN_BR_SEG", 6}})
