Autor Beitrag
jjturbo
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 516

Win2000 prof., WinXP prof.
D4 Stand., D5 Prof, D7 Prof, D2007 Prof.
BeitragVerfasst: Di 05.10.10 11:49 
Mojn Forum,

ich habe eine Maschine als .wrl-Datei bekommen.
Wenn ich diese Datei mit TGLFreeForm.LoadFromFile() öffne, dann dauert es sehr lange (ca. 3-4 Minuten) bis die Datei geladen wurde. Mit Blender läßt sich die Datei nach ca. 5 Sekunden ansehen.
Mache ich etwas falsch?

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
procedure Maschine3D_Laden(s:String);
var Mat: TGLMaterialLibrary;
begin

    HauptForm.GLFreeForm1.Visible := false;
    with HauptForm.GLFreeForm1 do begin
      Position.X := 0;
      Position.y := 0;
      Position.z := 0;
      Material.Texture.Disabled := false;
      MyGLFreeForm.MaterialLibrary := Mat;
      LoadFromFile(s);
      Scale.X := 1;
      Scale.Y := 1;
      Scale.Z := 1;
      ShowAxes   := false;
      TurnAngle  := 0;
      PitchAngle := 0;
      RollAngle  := 0;
    end;
  HauptForm.GLFreeForm1.Visible := True;


end;

_________________
Windows XP: Für die einen nur ein Betriebssystem - für die anderen der längste Virus der Welt...
jjturbo Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 516

Win2000 prof., WinXP prof.
D4 Stand., D5 Prof, D7 Prof, D2007 Prof.
BeitragVerfasst: Mo 11.10.10 09:29 
Ich habe jetzt viel probiert und gestöbert, aber leider keine Lösung gefunden.
Wenn ich ein anderes Dateiformat wähle gehts innerhalb von 6 Sekunden (*.3ds oder *.obj).

_________________
Windows XP: Für die einen nur ein Betriebssystem - für die anderen der längste Virus der Welt...
Martok
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 3661
Erhaltene Danke: 604

Win 8.1, Win 10 x64
Pascal: Lazarus Snapshot, Delphi 7,2007; PHP, JS: WebStorm
BeitragVerfasst: Mo 11.10.10 09:43 
Ich würde vermuten, dann ist der Importer von GLScene kaputt.

Welches .wrl ist das? VRML? Die Endung an sich sagt ja erstmal nicht viel...

_________________
"The phoenix's price isn't inevitable. It's not part of some deep balance built into the universe. It's just the parts of the game where you haven't figured out yet how to cheat."
jjturbo Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 516

Win2000 prof., WinXP prof.
D4 Stand., D5 Prof, D7 Prof, D2007 Prof.
BeitragVerfasst: Mo 11.10.10 10:04 
Ja, ich meine es war VRML.
Ich habe mal ein paar Haltepunkte in den GLScene Dateien gesetzt, irgendwo gab es einen Parser, in dem hat es so lange gedauert. Dort fanden sehr viele String-Vergleiche statt. Wollte aber nicht zu tief eintauchen und habe an der Stelle aufgegeben.

_________________
Windows XP: Für die einen nur ein Betriebssystem - für die anderen der längste Virus der Welt...