Forum > OpenGL
[ May be Solved] Problem installing GLscene
BlueIcaro:
Hello, I download the last GLscene SVN, but I got he followings errors:
--- Quote ---C:\lazarus\components\Glscne\Source\GLSceneForm.pas(722,29) Error: Identifier not found "GetDesigningBorderStyle"
C:\lazarus\components\Glscne\Source\GLSceneForm.pas(738,29) Error: Identifier not found "GetDesigningBorderStyle"
C:\lazarus\components\Glscne\Source\GLSceneForm.pas(750,41) Error: Identifier not found "GetDesigningBorderStyle"
C:\lazarus\components\Glscne\Source\GLSceneForm.pas(751,35) Error: Identifier not found "BorderStyleToWin32Flags"
C:\lazarus\components\Glscne\Source\GLSceneForm.pas(758,50) Error: Identifier not found "BorderStyleToWin32FlagsEx"
C:\lazarus\components\Glscne\Source\GLSceneForm.pas(773,41) Error: Identifier not found "GetDesigningBorderStyle"
C:\lazarus\components\Glscne\Source\GLSceneForm.pas(774,64) Error: Identifier not found "BorderStyleToWin32Flags"
C:\lazarus\components\Glscne\Source\GLSceneForm.pas(775,37) Error: Identifier not found "BorderStyleToWin32FlagsEx"
C:\lazarus\components\Glscne\Source\GLSceneForm.pas(879, stopping
--- End quote ---
I was "surfing" into the Lazarus's code, and I found that GetDesingningBorderStyle is a function, into Win32WsForm, but If I put this unit, into uses clause, I got a error that says: "Duplicate unit". SO I think it's no a problem about a missing unit into uses line.
Any idea?
Thanks in advance.
Leledumbo:
Please post the unit's uses clause, in both interface and implementation section.
BlueIcaro:
--- Quote from: Leledumbo on September 17, 2011, 06:01:33 am ---Please post the unit's uses clause, in both interface and implementation section.
--- End quote ---
Hello, Thanks Leledumbo for your answer. But I solved the problem by my self.
I delete the folder with the glscene files, copy into the folder a fresh files.
I think my problem, was that I download some svn versions from svn glscene version, also I mixed files from diferences versions.
But, I got a error, Compilers says: "Could not determine the overload functions", in a VectorGeometry function into VectorGeometry file.
The error:
--- Quote ---C:\lazarus\components\Glscne\Source\Base\VectorGeometry.pas(3803,32) Error: Can't determine which overloaded function to call
--- End quote ---
The line was in the
--- Code: Pascal [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---function InterpolatePower(const Start, Stop, Delta: Single; const DistortionDegree: Single): Single;(...)Result := (Stop - Start) * VectorGeometry.Power(Delta, Round(DistortionDegree)) + Start(...) So I changed the line for this one
--- Code: Pascal [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---Result := (Stop - Start) * Math.Power(Delta, Round(DistortionDegree)) + Start
And Now I can install the Glscene package.
/BlueIcaro.
P.D. I installed Glscene under Lazarus 0.9.31 and FPC 2.5.1
Leledumbo:
Glad you made it work. For function power problem, you might want to check VectorGeometry.Power, just to ensure that it doesn't behave differently from Math.Power...
BlueIcaro:
--- Quote from: Leledumbo on September 17, 2011, 02:52:51 pm ---Glad you made it work. For function power problem, you might want to check VectorGeometry.Power, just to ensure that it doesn't behave differently from Math.Power...
--- End quote ---
Hello Leledumbo, I was looking througth the source, and I find that the function in Glscene returns a Single, and the "Original" functions in Math unit (FPC unit) returns a Float.
Also I found in VectorGeometry unit this line:
--- Code: Pascal [+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i < x.length; i++) { x[i].style.maxHeight='none'; x[i].style.height = Math.min(x[i].clientHeight+15,306)+'px'; x[i].style.resize = "vertical";}};} ---SysUtils{$ifdef GEOMETRY_NO_ASM}, Math{$endif};
So, this is the reason why I must use Math.power to compile. But I read at the begin of the unit,
--- Quote --- As a general rule, procedures implementations (asm or not) are the fastest
(up to 800% faster than function equivalents), due to reduced return value
duplication overhead (the exception being the matrix operations).<p>
For better performance, it is recommended <b>not</b> to use the "Math" unit
that comes with Delphi, and only use functions/procedures from this unit
(the single-based functions have been optimized and are up to 100% faster,
than extended-based ones from "Math")
--- End quote ---
Well, I think my solutions it's a "temp" solution.
In VectoryUnit, only there declaration of power function with the overload instruccion. So I still looking for the original definition in Glscene source.
/BlueIcaro
Navigation
[0] Message Index
[#] Next page