📄 simpleinstrumentpanel.gls
字号:
GL_Studio_Version: 3.0.1003
DocumentPreferences:
{
LineColor: 70 74 70 191
FillColor: 249 255 244 255
BlendColor: 255 255 255 255
TextColor: 0 0 0 255
GridColor: 0 0 0 255
AxesColor: 0 0 0 255
LineWidth: 1
LineStipplePattern: 65535
LineStippleMultiplier: 1
GridSpacing: 1
SnapToGrid: 1
ShowAxes: 1
ShowGrid: 0
PreviewAnimations: 1
LightingEnabled: 0
Shading: FLAT
DepthTest: 0
AntiAlias: 0
AlphaMode: ALPHA_MODE_256_LEVEL
PolygonMode: POLY_MODE_OUTLINE
PolygonEnd: POLY_CLOSED
PolygonOffset: 0
TextureIndex: -1
TextureRepeat: 1
TextureMap: TEXTURE_MAP_DECAL
TextureMinFilter: TEXTURE_FILTER_LINEAR
TextureMagFilter: TEXTURE_FILTER_LINEAR
FontName: Arial
Spacing: SPACING_PROPORTIONAL
HJustification: TEXT_ALIGN_CENTER
FixedSize: 18
FixedSpacing: 10
FontStrikethrough: 0
FontWordWrap: 0
TextOutline: 0
TextBackground: 0
TextInverseVideo: 0
TextVertical: 0
RemoveBackfaces: 0
BlinkMode: 0
PickMode: 1
Material: 0
BlinkRate: 2
Window:
{
X: 122
Y: 197
W: 550
H: 624
AzimuthAngle: 0
IncidenceAngle: 0
TwistAngle: 0
View: VIEW_XY
CenterX: 512
CenterY: 337.5
Scale: 1.952727318
}
}
DisplayFrame: EditorDisplayFrame
{
ComponentHeaderFile: SimpleInstrumentPanel.h
Width: 1024
Height: 675
Title: SimpleInstrumentPanel
InitialX: 0
InitialY: 0
MaxWidth: -1
MaxHeight: -1
MinWidth: -1
MinHeight: -1
Resizable: 1
HasBorder: 1
MainFileName:
DerivedClass: SimpleInstrumentPanelClass
StandaloneHeaderFile: SimpleInstrumentPanelApp.h
StandaloneSourceFile: SimpleInstrumentPanelApp.cpp
StandaloneClassInstance: simpleInstrumentPanel
ComponentSourceFile: SimpleInstrumentPanel.cpp
ComponentUserBaseClass: 0
ClassDerivedFrom:
ClassDerivedFromInit:
XWindowsHeaderFile: SimpleInstrumentPanelXWin.h
XWindowsSourceFile: SimpleInstrumentPanelXWin.cpp
XWindowsClassInstance: simpleInstrumentPanel
RootName: SimpleInstrumentPanel
FillInFromRoot: 1
GeneratedSourcePath: .\source\
ExtraCodeSource:
ExtraCodeHeader:
MainLoopSource:
MainInitSource:
ClassCodeSource: #$STRING_START$#
#$ITEM_TYPE$#2#$TYPE$#void#$NAME$#Initialize#$ARGS$##$BODY$##$GEN_BODY$#1#$PPP$#0#$COMMENT$#
#$ITEM_TYPE$#3#$TYPE$#void#$NAME$#Calculate#$ARGS$#double time#$BODY$#objects->Group::Calculate(time); // Do not remove (for normal operations)
if(!Testing())
{
altimeterDevice->Altitude(_newAltitude);
adiDevice->Roll(_newRoll);
adiDevice->Pitch(_newPitch);
mfdDevice->SetResource("Mode",_newMFDMode);
}
#$GEN_BODY$#1#$PPP$#0#$COMMENT$#
#$ITEM_TYPE$#1#$TYPE$#float#$NAME$#_newRoll#$ARGS$#0.0#$BODY$##$GEN_BODY$#1#$PPP$#1#$COMMENT$#
#$ITEM_TYPE$#1#$TYPE$#float#$NAME$#_newPitch#$ARGS$#0.0#$BODY$##$GEN_BODY$#1#$PPP$#1#$COMMENT$#
#$ITEM_TYPE$#1#$TYPE$#float#$NAME$#_newAltitude#$ARGS$#0.0#$BODY$##$GEN_BODY$#1#$PPP$#1#$COMMENT$#
#$ITEM_TYPE$#1#$TYPE$#std::string#$NAME$#_newMFDMode#$ARGS$#HSI#$BODY$##$GEN_BODY$#1#$PPP$#1#$COMMENT$##$STRING_END$#
Properties:
{
Item:
{
FillIn: 1
Name: Testing
Type: bool
Args: ture
VariablePPP: 1
SetPPP: 0
GetPPP: 0
MemberVariableUsed: 1
MemberVariableName: _testing
SetMethodUsed: 1
SetMethodName: Testing
SetMethodBody: #$STRING_START$#_testing = value;
adiDevice->Testing(value);
altimeterDevice->Testing(value);
mfdDevice->SetResource("Testing",value ? "TRUE" : "FALSE");#$STRING_END$#
GetMethodUsed: 1
GetMethodName: Testing
}
}
ClassDeclarations:
GenerateComments: 1
GenerateSeparateMain: 0
DCS_Length: 75
Projection: ORTHOGRAPHIC
Buffering: DOUBLE_BUFFER
DepthBuffer: 1
StencilBuffer: 0
AccumBuffer: 0
AlphaBuffer: 0
Multisample: 0
FullScreen: 0
ViewCulling: 1
RedrawType: REDRAW_CONSTANT
ApplicationType: STANDALONE
FrameRate: 30
BackgroundColor: 255 255 255 255
SoundFiles:
{
}
TexturePalette:
{
0:
{
Filename: ./textures/simple_instrument_panel.png
GenerateInline: 1
CompressionFactor: 75
CompressedSize: 729424
ImageCodec: GLS_CODEC_LZ77
ReverseAlpha: 0
}
1:
{
Filename: ./textures/altimeter.png
GenerateInline: 1
CompressionFactor: 75
CompressedSize: 240267
ImageCodec: GLS_CODEC_LZ77
ReverseAlpha: 1
}
}
MaterialPalette: 1
0 1 51 51 51 255 204 204 204 255 0 0 0 255 0 0 0 255 0 "Default Material"
InitialEyePointName: <Default Ortho>
RuntimeAvailableAttributes: 17
ObjectClass: GLPolygon
{
Name: panel
Location: 514.5 337.5 0
Visible: 1
Pickable: 1
RotationOrigin: 0 0 0
Rotation: 0 0 0
DynamicTranslate: 0 0 0
DynamicScale: 1 1 1
DCSMatrix: 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1
LineWidth: 1
CullBackFace: 0
AlphaMode: ALPHA_MODE_256_LEVEL
AntiAlias: 0
DepthTest: 2
Color: 0 0 0 255
TextureIndex: 0
TextureRepeat: 1
TextureMap: TEXTURE_MAP_REPLACE
BlendColor: 255 255 255 255
TextureMinFilter: TEXTURE_FILTER_LINEAR
TextureMagFilter: TEXTURE_FILTER_LINEAR
PolygonMode: POLY_MODE_FILLED
PolygonEnd: POLY_CLOSED
PolygonOffset: 0
Shading: FLAT
LineStippleMultiplier: 1
LineStipplePattern: 65535
Blink: 0
BlinkRate: 2
LightingEnabled: 1
MaterialIndex: 0
Vertices: 4
-512.5 -337.5 0 134 13 13 255
512.5 -337.5 0 134 13 13 255
512.5 337.5 0 134 13 13 255
-512.5 337.5 0 134 13 13 255
TexturePoints:
511.5 -337.5 0
-512.5 -337.5 0
-512.5 686.4995117 0
511.5 686.4995117 0
TextureCoords: 4
0 -8.149072528e-009 0
1.000976563 -8.149072528e-009 0
1.000976563 0.6591799855 0
0 0.6591799855 0
Normals: 4
0 0 1
0 0 1
0 0 1
0 0 1
ProtectionMode: PUBLIC
Locked: 0
EndMarker: panel
}
ObjectClass: GlsKnob 1
{
Name: rollGlsKnob
Location: 192.0164185 103.9758759 0
Visible: 1
Pickable: 1
RotationOrigin: 0 0 0
Rotation: 0 0 0
DynamicTranslate: 0 0 0
DynamicScale: 1 1 1
DCSMatrix: -0.7341935967 0.678940176 0 0 -0.678940176 -0.7341935967 0 0 0 0 1 0 0 0 0 1
LineWidth: 1
CullBackFace: 0
AlphaMode: ALPHA_MODE_256_LEVEL
AntiAlias: 0
DepthTest: 2
Color: 0 0 0 255
TextureIndex: -1
TextureRepeat: 1
TextureMap: TEXTURE_MAP_REPLACE
BlendColor: 255 255 255 255
TextureMinFilter: TEXTURE_FILTER_LINEAR
TextureMagFilter: TEXTURE_FILTER_LINEAR
PolygonMode: POLY_MODE_OUTLINE
PolygonEnd: POLY_CLOSED
PolygonOffset: 0
Shading: FLAT
LineStippleMultiplier: 1
LineStipplePattern: 65535
Blink: 0
BlinkRate: 2
LightingEnabled: 0
MaterialIndex: 0
Vertices: 8
-97.49039459 -97.49047852 0 255 255 255 255
97.49002075 -97.49047852 0 255 255 255 255
97.49002075 97.49143982 0 255 255 255 255
-97.49039459 97.49143982 0 255 255 255 255
-97.49039459 -97.49047852 0 255 255 255 255
97.49002075 -97.49047852 0 255 255 255 255
97.49002075 97.49143982 0 255 255 255 255
-97.49039459 97.49143982 0 255 255 255 255
TexturePoints:
-3.827651978 97.89161682 0
97.8913269 3.827301025 0
3.827224731 -97.89198303 0
-97.89186859 -3.828048706 0
PerformGroupCullCheck: 0
CullTestChildren: 1
AngleRange: 270
NumDetents: 7
DetentPositions: 7
0
16
33
50
66
83
100
PositionVal: 0
Continuous: 0
WhichObject: 0
StartAngle: 0
EmitDetentValEvent: 1
EmitPositionValEvent: 1
DetentVal: 1
PositionVal: 0
InitializationCode: self->DetentVal(4);
ObjectCallbackCode: #$STRING_START$#bool rval = false;
if (ObjectEventIs(ev, "DetentVal"))
{
switch(rollGlsKnob->DetentVal())
{
case 1:
_newRoll = -30.0f;
break;
case 2:
_newRoll = -20.0f;
break;
case 3:
_newRoll = -10.0f;
break;
case 4:
_newRoll = 0.0f;
break;
case 5:
_newRoll = 10.0f;
break;
case 6:
_newRoll = 20.0f;
break;
case 7:
_newRoll = 30.0f;
break;
}
rval = true;
}
return rval;
#$STRING_END$#
ProtectionMode: PUBLIC
Locked: 0
IsStatic: 0
ObjectClass: GLPolygon
{
Name: roll
Location: 192.0166931 103.9754105 0
Visible: 1
Pickable: 1
RotationOrigin: -0.004653930664 -0.02825164795 0
Rotation: 0 0 0
DynamicTranslate: 0 0 0
DynamicScale: 1 1 1
DCSMatrix: -0.736872389 0.6760318648 0 0 -0.6760318648 -0.736872389 0 0 0 0 1 0 0 0 0 1
LineWidth: 1
CullBackFace: 0
AlphaMode: ALPHA_MODE_256_LEVEL
AntiAlias: 0
DepthTest: 2
Color: 0 0 0 255
TextureIndex: 0
TextureRepeat: 1
TextureMap: TEXTURE_MAP_REPLACE
BlendColor: 255 255 255 255
TextureMinFilter: TEXTURE_FILTER_LINEAR
TextureMagFilter: TEXTURE_FILTER_LINEAR
PolygonMode: POLY_MODE_FILLED
PolygonEnd: POLY_CLOSED
PolygonOffset: 0
Shading: FLAT
LineStippleMultiplier: 1
LineStipplePattern: 65535
Blink: 0
BlinkRate: 2
LightingEnabled: 0
MaterialIndex: 0
Vertices: 4
97.48974609 4.19846344 0 134 13 13 255
-4.197753906 97.49190521 0 134 13 13 255
-97.49066925 -4.197822571 0 134 13 13 255
4.198669434 -97.49001312 0 134 13 13 255
TexturePoints:
-45.12889099 1032.081421 0
709.4229736 339.8225708 0
17.1696167 -414.7306519 0
-737.3876953 277.5228882 0
TextureCoords: 4
0.2187719941 0.6455097198 0
0.3535379171 0.6455100775 0
0.3535377681 0.7802766562 0
0.2187715173 0.7802757025 0
Normals: 4
0 0 1
0 0 1
0 0 1
0 0 1
ProtectionMode: PUBLIC
Locked: 0
EndMarker: roll
}
Preview: 1
EndMarker: rollGlsKnob
}
ObjectClass: GlsKnob 1
{
Name: pitchGlsKnob
Location: 349.9159241 102.8627777 0
Visible: 1
Pickable: 1
RotationOrigin: 1.084075928 -0.86277771 0
Rotation: 0 0 0
DynamicTranslate: 0 0 0
DynamicScale: 1 1 1
DCSMatrix: -0.7799913629 0.6257902794 0 0 -0.6257902794 -0.7799913629 0 0 0 0 1 0 0 0 0 1
LineWidth: 1
CullBackFace: 0
AlphaMode: ALPHA_MODE_256_LEVEL
AntiAlias: 0
DepthTest: 2
Color: 0 0 0 255
TextureIndex: -1
TextureRepeat: 1
TextureMap: TEXTURE_MAP_REPLACE
BlendColor: 255 255 255 255
TextureMinFilter: TEXTURE_FILTER_LINEAR
TextureMagFilter: TEXTURE_FILTER_LINEAR
PolygonMode: POLY_MODE_OUTLINE
PolygonEnd: POLY_CLOSED
PolygonOffset: 0
Shading: FLAT
LineStippleMultiplier: 1
LineStipplePattern: 65535
Blink: 0
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -