[fpc-pascal] Adding a array of float in ressource and use it ?

fredvs fiens at hotmail.com
Mon Mar 6 12:30:50 CET 2017


Hello Michael and thanks for answer.

>You must write 
>  FileBuffer.Data.WriteBuffer(buffer[0],Length(Buffer)*Sizeof(Float)); 

Ha, perfect, many thanks.

But there is something that I do not catch, why is it working for integer ?

Sizeof Integer is 2 bits so, normally:

FileBuffer.Data.WriteBuffer(buffer[0],Length(Buffer)); 

should not work (but it works) ---> Length(Buffer) = 1/2 * 
Length(Buffer)*Sizeof(integer)

?

Fre;D



-----
Many thanks ;-)
--
View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Adding-a-array-of-float-in-ressource-and-use-it-tp5727765p5727780.html
Sent from the Free Pascal - General mailing list archive at Nabble.com.



More information about the fpc-pascal mailing list