Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
5edb94e2
Commit
5edb94e2
authored
Sep 19, 2007
by
claes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*** empty log message ***
parent
7a61f589
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
232 additions
and
120 deletions
+232
-120
java/jpwr/jop/src/GeDynXYCurve.java
java/jpwr/jop/src/GeDynXYCurve.java
+125
-34
src/changelog.txt
src/changelog.txt
+3
-1
src/doc/man/en_us/changelog.html
src/doc/man/en_us/changelog.html
+100
-84
wb/changelog.txt
wb/changelog.txt
+4
-1
No files found.
java/jpwr/jop/src/GeDynXYCurve.java
View file @
5edb94e2
/*
* Proview $Id: GeDynXYCurve.java,v 1.
1 2007-09-17 15:35:28
claes Exp $
* Proview $Id: GeDynXYCurve.java,v 1.
2 2007-09-19 15:08:35
claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
...
...
@@ -45,6 +45,8 @@ public class GeDynXYCurve extends GeDynElem {
int
noofpoints
;
int
noOfPoints
;
int
xAttrType
;
int
yAttrType
;
public
float
[]
curveX
;
public
float
[]
curveY
;
boolean
updateAttrFound
;
...
...
@@ -96,6 +98,13 @@ public class GeDynXYCurve extends GeDynElem {
this
.
fill_curve
=
fill_curve
;
}
public
void
connect
()
{
xAttrType
=
GeDyn
.
getTypeId
(
x_attr
);
switch
(
datatype
)
{
case
GeDyn
.
eCurveDataType_XYArrays
:
yAttrType
=
GeDyn
.
getTypeId
(
y_attr
);
break
;
}
String
attrName
=
dyn
.
getAttrName
(
update_attr
);
if
(
attrName
.
compareTo
(
""
)
!=
0
)
{
GdhrRefObjectInfo
ret
=
dyn
.
en
.
gdh
.
refObjectInfo
(
attrName
);
...
...
@@ -260,11 +269,93 @@ public class GeDynXYCurve extends GeDynElem {
size
=
noOfPoints
*
2
+
1
;
break
;
}
// Read x-array
CdhrFloatArray
rxf
;
CdhrIntArray
rxi
;
switch
(
xAttrType
)
{
case
Pwr
.
eType_Float32
:
rxf
=
dyn
.
en
.
gdh
.
getObjectInfoFloatArray
(
attrName
,
size
);
if
(
rxf
.
evenSts
())
return
;
switch
(
datatype
)
{
case
GeDyn
.
eCurveDataType_XYArrays
:
curveX
=
new
float
[
noOfPoints
];
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
curveX
[
i
]
=
(
rxf
.
value
[
i
]
-
x_min_value
)
/
(
x_max_value
-
x_min_value
);
break
;
case
GeDyn
.
eCurveDataType_PointArray
:
curveX
=
new
float
[
noOfPoints
];
curveY
=
new
float
[
noOfPoints
];
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
{
curveX
[
i
]
=
(
rxf
.
value
[
2
*
i
]
-
x_min_value
)
/
(
x_max_value
-
x_min_value
);
curveY
[
i
]
=
(
rxf
.
value
[
2
*
i
+
1
]
-
y_min_value
)
/
(
y_max_value
-
y_min_value
);
}
dyn
.
repaintNow
=
true
;
break
;
case
GeDyn
.
eCurveDataType_TableObject
:
noOfPoints
=
(
int
)
rxf
.
value
[
0
];
if
(
noOfPoints
>
noofpoints
)
noOfPoints
=
noofpoints
;
if
(
attrSize
<
noOfPoints
)
noOfPoints
=
attrSize
;
curveY
=
new
float
[
noOfPoints
];
curveX
=
new
float
[
noOfPoints
];
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
{
curveX
[
i
]
=
(
rxf
.
value
[
2
*
i
+
1
]
-
x_min_value
)
/
(
x_max_value
-
x_min_value
);
curveY
[
i
]
=
(
rxf
.
value
[
2
*
i
+
2
]
-
y_min_value
)
/
(
y_max_value
-
y_min_value
);
}
dyn
.
repaintNow
=
true
;
break
;
}
break
;
case
Pwr
.
eType_Int32
:
case
Pwr
.
eType_Int16
:
case
Pwr
.
eType_Int8
:
case
Pwr
.
eType_UInt32
:
case
Pwr
.
eType_UInt16
:
case
Pwr
.
eType_UInt8
:
rxi
=
dyn
.
en
.
gdh
.
getObjectInfoIntArray
(
attrName
,
size
);
if
(
rxi
.
evenSts
())
return
;
CdhrFloatArray
rx
=
dyn
.
en
.
gdh
.
getObjectInfoFloatArray
(
attrName
,
size
);
if
(
rx
.
evenSts
())
switch
(
datatype
)
{
case
GeDyn
.
eCurveDataType_XYArrays
:
curveX
=
new
float
[
noOfPoints
];
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
curveX
[
i
]
=
((
float
)
rxi
.
value
[
i
]
-
x_min_value
)
/
(
x_max_value
-
x_min_value
);
break
;
case
GeDyn
.
eCurveDataType_PointArray
:
curveX
=
new
float
[
noOfPoints
];
curveY
=
new
float
[
noOfPoints
];
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
{
curveX
[
i
]
=
((
float
)
rxi
.
value
[
2
*
i
]
-
x_min_value
)
/
(
x_max_value
-
x_min_value
);
curveY
[
i
]
=
((
float
)
rxi
.
value
[
2
*
i
+
1
]
-
y_min_value
)
/
(
y_max_value
-
y_min_value
);
}
dyn
.
repaintNow
=
true
;
break
;
case
GeDyn
.
eCurveDataType_TableObject
:
noOfPoints
=
(
int
)
rxi
.
value
[
0
];
if
(
noOfPoints
>
noofpoints
)
noOfPoints
=
noofpoints
;
if
(
attrSize
<
noOfPoints
)
noOfPoints
=
attrSize
;
curveY
=
new
float
[
noOfPoints
];
curveX
=
new
float
[
noOfPoints
];
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
{
curveX
[
i
]
=
((
float
)
rxi
.
value
[
2
*
i
+
1
]
-
x_min_value
)
/
(
x_max_value
-
x_min_value
);
curveY
[
i
]
=
((
float
)
rxi
.
value
[
2
*
i
+
2
]
-
y_min_value
)
/
(
y_max_value
-
y_min_value
);
}
dyn
.
repaintNow
=
true
;
break
;
}
break
;
default
:
return
;
}
// Read y-array
switch
(
datatype
)
{
case
GeDyn
.
eCurveDataType_XYArrays
:
attrName
=
dyn
.
getAttrName
(
y_attr
);
...
...
@@ -272,39 +363,39 @@ public class GeDynXYCurve extends GeDynElem {
if
(
attrSize
<
noOfPoints
)
noOfPoints
=
attrSize
;
CdhrFloatArray
ry
=
dyn
.
en
.
gdh
.
getObjectInfoFloatArray
(
attrName
,
noOfPoints
);
if
(
ry
.
evenSts
())
return
;
curveY
=
new
float
[
noOfPoints
];
curveX
=
new
float
[
noOfPoints
];
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
{
curveY
[
i
]
=
(
ry
.
value
[
i
]
-
y_min_value
)
/
(
y_max_value
-
y_min_value
);
curveX
[
i
]
=
(
rx
.
value
[
i
]
-
x_min_value
)
/
(
x_max_value
-
x_min_value
);
}
dyn
.
repaintNow
=
true
;
break
;
case
GeDyn
.
eCurveDataType_PointArray
:
curveY
=
new
float
[
noOfPoints
];
curveX
=
new
float
[
noOfPoints
];
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
{
curveX
[
i
]
=
(
rx
.
value
[
2
*
i
]
-
x_min_value
)
/
(
x_max_value
-
x_min_value
);
curveY
[
i
]
=
(
rx
.
value
[
2
*
i
+
1
]
-
y_min_value
)
/
(
y_max_value
-
y_min_value
);
}
dyn
.
repaintNow
=
true
;
break
;
case
GeDyn
.
eCurveDataType_TableObject
:
noOfPoints
=
(
int
)
rx
.
value
[
0
];
if
(
noOfPoints
>
noofpoints
)
noOfPoints
=
noofpoints
;
if
(
attrSize
<
noOfPoints
)
noOfPoints
=
attrSize
;
curveY
=
new
float
[
noOfPoints
];
curveX
=
new
float
[
noOfPoints
];
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
{
curveX
[
i
]
=
(
rx
.
value
[
2
*
i
+
1
]
-
x_min_value
)
/
(
x_max_value
-
x_min_value
);
curveY
[
i
]
=
(
rx
.
value
[
2
*
i
+
2
]
-
y_min_value
)
/
(
y_max_value
-
y_min_value
);
CdhrFloatArray
ryf
;
CdhrIntArray
ryi
;
switch
(
yAttrType
)
{
case
Pwr
.
eType_Float32
:
ryf
=
dyn
.
en
.
gdh
.
getObjectInfoFloatArray
(
attrName
,
noOfPoints
);
if
(
ryf
.
evenSts
())
return
;
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
curveY
[
i
]
=
(
ryf
.
value
[
i
]
-
y_min_value
)
/
(
y_max_value
-
y_min_value
);
dyn
.
repaintNow
=
true
;
break
;
case
Pwr
.
eType_Int32
:
case
Pwr
.
eType_Int16
:
case
Pwr
.
eType_Int8
:
case
Pwr
.
eType_UInt32
:
case
Pwr
.
eType_UInt16
:
case
Pwr
.
eType_UInt8
:
ryi
=
dyn
.
en
.
gdh
.
getObjectInfoIntArray
(
attrName
,
noOfPoints
);
if
(
ryi
.
evenSts
())
return
;
for
(
int
i
=
0
;
i
<
noOfPoints
;
i
++)
curveY
[
i
]
=
((
float
)
ryi
.
value
[
i
]
-
y_min_value
)
/
(
y_max_value
-
y_min_value
);
dyn
.
repaintNow
=
true
;
break
;
default
:
return
;
}
dyn
.
repaintNow
=
true
;
break
;
}
...
...
src/changelog.txt
View file @
5edb94e2
...
...
@@ -43,4 +43,6 @@
070720 cs co Listwidgets: Doubleclick and Enter activates a row.
070821 cs convert Template with includes inserted at structfile generation.
070905 cs doc New Guide to I/O Systems.
070906 cs statussrv Functionality to view userstatus added.
\ No newline at end of file
070906 cs statussrv Functionality to view userstatus added.
070918 cs wbl New systemclass $ClassLost to replace lost classes.
070919 cs wbl New class XyCurve to view a curve of points with x,y coordiantes.
\ No newline at end of file
src/doc/man/en_us/changelog.html
View file @
5edb94e2
This diff is collapsed.
Click to expand it.
wb/changelog.txt
View file @
5edb94e2
...
...
@@ -70,4 +70,7 @@
070824 cs wb Bugfix in WbEnvironment object, only the first nine pathes were used.
070827 cs wtt Objects in the navigator beneath a MountObject are viewed with classes from their dbs-file.
070905 cs utl Bugfix in listdescriptor. Superclass attributes where not printed.
070905 cs wb Bugfix in ldh_GetClassListAttrRef, success status was returned though list was empty.
\ No newline at end of file
070905 cs wb Bugfix in ldh_GetClassListAttrRef, success status was returned though list was empty.
070917 cs plc Bugfix, reference connections could not be set in gtk.
070918 cs wb Lost classes replaced with $ClassLost when reading wb_load file.
070919 cs wb Defaultvalues inserted into template objects when new attribute objects are added to a class.
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment