September 18, 200421 yr Hi all.I think I may have discovered a problem with the VTPChildPoint line structure.It seems the newest TMFViewer will show an error with a VTPChildPoint line, unless the line has at least 4 points:You need to use the latest TMFViewer's "Draw Wide Lines as Polygons" view option.For example: VTPPolyMethod2 3, _IsLine_, 0; Cell 25 x 11, offset 150,217 VTPWidePoint 10605, _UseWidth_, 7102, 2 VTPWidePointWidth 8 VTPChildPoint 0, 0, -1, 0 VTPChildPoint 0, 0, 1, 0 is apparently illegal, while: VTPPolyMethod2 4, _IsLine_, 0; Cell 25 x 11, offset 150,217 VTPWidePoint 10605, _UseWidth_, 7102, 3 VTPWidePointWidth 8 VTPChildPoint 0, 0, -1, 0 VTPChildPoint 0, 0, 1, 0 VTPChildPoint 0, 0, 0, 0 ...is just fine ( the difference being the use of 4 points in the structure ).I don't know if this undocumented problem with TMFViewer will cause problems in FS9, but it may. So it may be that VTPChildPont line types require a minimum of 4 points, and may explain why MS uses 4-point lines as the default format for bridges.http://forums.avsim.net/user_files/91515.jpgDick
September 19, 200421 yr Hello Dick,It is a pitty that the files we attach to our posts get lost. Still I point you out to this thread:http://forums.avsim.net/dcboard.php?az=sho..._id=18859&page=I am using VTP Lines in SBuilder as follows:1) I do not allow the width of the line to be greater than 2552) I start the line with 2 Child points. Thes 2 Child points are perpendicular to the first line segment and their distance is the starting width of the line. The "mean position" of these 2 Child Points is the position of the starting point of the source line.3) I end lines with 2 child points which are perpendicular to the last segment of the line. Again their distance is the width of the last point in the source line. The "mean position" of these 2 Child Points is the position of the ending point of the source line.4) I created an option in the VTP file import which I call "Remove Hooks". If this option (a check box) is set, Sbuilder imports 4 points lines as 2 points. If I do not set the option, Sbuilder import the points as if they all are different (as for example you see them in LWMViewer).If you want to test the BGL import in SBuilder please send me an email.Kind Regards. Luis
September 20, 200421 yr Hello Luis,if I understand you right, you can delete during the BGL import into SBuilder the first and the last point of a VTP-line using VTPChildpoint structures. When you import a 4 point line it is reduced to 2 points, right. Is such a line displayed without problems?I think, Dick points out a problem in TMFviewer and the FSimulator with the display of a line with 2 or 3 points. It sounds plausible in my eyes, because of the location of the 'virtual' endpoints of a line between the 1. and 2. and the n-1 and n.th line point. If there are only 2 or 3 points, the displayed line had no 'virtual' endpoints. Maybe a result of the algorithm to calculate the postion of the 'virtual' endpoints in the fs engine.Best regards, Edgar
September 20, 200421 yr Author Hi Edgar.The childpoint structure assumes the first 2 and last 2 points are "hooks", set at 90* to the line, to define the squared off start and end widths. Of course, the SDK neglects to mention this... they only included some info because we already discovered it on our own ( MS already used the hooks in FS2002, so the SDK writers certainly knew about them then! ). The SDK tries to describe the structure as a shortcut for writing code, but in fact, the structure is entirely different ( and better ).By it's nature, the childpoint structure requires a minimum of 4 points to describe the start and end of the line. In the case of the 3-point line, it actually adds an extra point! It's location is S0* E0*. You can see it in TMFViewer, using the view-as-poly feature.I don't know what a 2-point line using the childpoint structure would do... I'll look tonight if I get time.Dick
Create an account or sign in to comment