-
Content Count
85 -
Joined
-
Last visited
Everything posted by skyzoframe[hun]
-
How can I use pointers to access the value of a dmArray = TList<dmRecord> record?
skyzoframe[hun] posted a topic in Algorithms, Data Structures and Class Design
Greetings everyone, I want to sort a tList with some kind of record parameter. Somehow I need to use pointers to get to the record without using the name of the record. In this example I am using the name "Rec.x". However, in the future I would like to use "Rec.y", "Rec.z","Rec.ID" or any other record value in the sort. // See below In fact, I have never used pointers before. "function Foo.BubbleSort(AList: dmA00; SomeParameterHere:IsSomething ;out Error: String): Boolean;" ... " if jRec.SomeParameterHere > j1Rec.SomeParameterHere then" kind regards Zoltan.K type dmR00 = Record ID : integer; x,y,z : integer; End; ... dmA00 = TList<dmR00>; ... function Foo.BubbleSort(AList: dmA00; out Error: String): Boolean; var jRec, j1Rec: dmR00; i,j : integer; begin try for i := 0 to AList.Count - 2 do begin for j := 0 to AList.Count - 2 - i do begin // clear record jRec := default(dmR00); j1Rec := default(dmR00); // fill record jRec := aList[j]; j1Rec := aList[j+1]; // check record if jRec.x > j1Rec.x then begin AList[j] := j1Rec; AList[j + 1] := jRec; end; end; end; Result := True; except on E: Exception do begin Error := ('Exception class name = ' + E.ClassName + sLineBreak + 'Exception message = ' + E.Message); Result := False; end; end; end; -
I have the same question. I cannot save the *.xmlst file that I created at runtime in UTF-8-BOM format.
-
How can I use pointers to access the value of a dmArray = TList<dmRecord> record?
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
Yes, it is just an example. I wanted to get to the record-element. With the help of pointers. But it is not clear to me how to do it. I have no idea if it will be possible. Alternative solution can be a key-parameter, and each sorting record element I can handle with case statement. type dmR00 = Record ID : integer;//key-0 x,//key-1 y,//key-2 z : integer;//key-3 End; ... dmA00 = TList<dmR00>; ... function Foo.BubbleSort(AList: dmA00; key:byte; out Error: String): Boolean; var jRec, j1Rec: dmR00; i,j : integer; begin try for i := 0 to AList.Count - 2 do begin for j := 0 to AList.Count - 2 - i do begin // clear record jRec := default(dmR00); j1Rec := default(dmR00); // fill record jRec := aList[j]; j1Rec := aList[j+1]; // check record case key of 0: begin if jRec.ID > j1Rec.ID then begin AList[j] := j1Rec; AList[j + 1] := jRec; end; end; 1: begin if jRec.x > j1Rec.x then begin AList[j] := j1Rec; AList[j + 1] := jRec; end; end; 2: begin if jRec.y > j1Rec.y then begin AList[j] := j1Rec; AList[j + 1] := jRec; end; end; 3: begin if jRec.z > j1Rec.z then begin AList[j] := j1Rec; AList[j + 1] := jRec; end; end; end; end; end; Result := True; except on E: Exception do begin Error := ('Exception class name = ' + E.ClassName + sLineBreak + 'Exception message = ' + E.Message); Result := False; end; end; end; -
In App Purchase (consumable and subscription)
skyzoframe[hun] replied to Joe Sansalone's topic in Cross-platform
-
MediaPlayer Android play MP4 video issue
skyzoframe[hun] replied to pcplayer99's topic in Cross-platform
-
Playing an MP4 animation / unsupported media file / cppbuilder
skyzoframe[hun] replied to alank2's topic in FMX
It may not be too late. The example does not work because of the missing codeck pack. the solution: https://stackoverflow.com/questions/28910428/tmediaplayer-error-unsupported-media-file By Jim McKeeth the codeck.: https://www.codecguide.com/download_kl.htm Now all examples work fine. ..\Samples\Object Pascal\Multi-Device Samples\Device Sensors and Services\App Tethering\MediaPlayer\ and even the VideoPlayback sample works. -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] posted a topic in Algorithms, Data Structures and Class Design
Hi all. How to solve, one kind of irrational number storage in float? (For example Pi value) ( second reason. I want to solve a movement over an axis, in the most precious way over an help of pascal programing.) Regards k.z. -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
I think, the question already answered. Thanks, now i know what I have to do.. -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
I want 6 axis movement of one kind of robot. And I have a lot of irracional value. That has to be stored in memory. (Float value) -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
Should I have to check every coordinate value in every runtime because of the main coordinate array what I use? I am confused right now... -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
Please give me one kind of example. -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
if I slice 3D into 2D surface. What do you mean about [k*2^n] What do you mean? -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
Many irrational numbers must be used in 3D space. my problem is that it has to be stored in memory. usually in float value. which causes an error if I work in six axes -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
https://en.m.wikipedia.org/wiki/Cube Here check the formulas thread -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
Cube face diagonal or cube space diagonal. Irracional numbers also. (Cube edge 1 integer) -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
I want to adapt to the maximum software possibilities within the limits of Pascal. The hardware constans in this case.( One kind of parameter) -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
I got one MASTER coordinate system. After that 6 slave. That depends of each other in one kind of linear way. My problem is the first axis movement. (Because of reverse engineering) -
Algorithms. Irrational numer storage.Playing with 6 axis robot.
skyzoframe[hun] replied to skyzoframe[hun]'s topic in Algorithms, Data Structures and Class Design
I want 0.1 micron precious movement over 6axis robot. -
https://www.packtpub.com/
-
client pc database connection problem with interbase server
skyzoframe[hun] replied to muratcelik64's topic in Databases
I use Interbase, and I require these files on the client side. Install if not installed already.: vcredist_x64.exe or vcredist_x86.exe The main folder of the YourPrg.exe ibclient64.dll or gds32.dll.- 15 replies
-
Yes , you are right.
-
I mean, before you put anything into the array, you have to clear the record, then fill the record. If you don't do so, then there are the opportunity to create redundancy.
-
In these case, maybe you need one more row. LMyRecordWithValues := default (TMyRecordWithValues);
-
The best solution for converting the query into an array was developed by Pawel Glowacki in Chapter 9 of the Expert Delphi book. I use the same technique all the time, except I do everything at runtime. ToDoListSQLite.7z
-
@Rollo62 Do you have any solution for the problem? https://docwiki.embarcadero.com/CodeExamples/Sydney/en/FMXTCanvasFillFunctions_(Delphi)