I have a javascript string which is about 500K when being sent from the server in UTF-8. How can I tell its size in JavaScript?  I know that JavaScript uses UCS-2, so does that mean 2 bytes per character. However, does it depend on the JavaScript i...
I'm going to be storing a large array of byte values (most likely over a million) in Javascript. If I use a normal array with normal numbers, that will take 8 MB, because numbers are stored as IEEE doubles, but if I can store it as bytes, it wi...
I have an array in Javascript that has lot of sub arrays. What would be the best/simplest way to count how many bits/bytes the array holds? I'm gonna send the array to my PHP server, and it can only be 5kB big.  Is there a native method for this?...
I'm trying to make a javascript emulator, and i'd like it to be very light, so I don't want to load the "ROMs" with jQuery and jDataView. Si I made my own ROM loader in pure JS.  It works pretty well (thanks to many topics on this...
I have a function in JavaScript which is expecting a byte array to be passed into it from Native C++ code. For example:  function OnEvent(event, data1) {      console.log("data1[0] = " + data1[0]); }   I would like for it to print 0x55 or eve...
I am getting arrayBuffur from WebSocket connection, and I can get range of byte arrays that is  Guid created in c#.   How I can convert this guid bytes to string in javascript?  Guid="FEF38A56-67A9-46DF-B7D8-C52191CD70F4"  Bytes=[86, 138, 243...
I need to convert an array of 8 bytes into a double.  This is my starting array:  [170, 85, 255, 63, 205, 171, 170, 85]   and it should convert to -9.591053231630682E-105.  Each element of the array can be from 0 to 256....
Let's say I have a hexadecimal, for example "0xdc", how do I convert this hexadecimal string to a hexadecimal Number type in JS?   Literally just losing the quotes. The Number() constructor and parseInt() just converted it to an integer b...
I'm not sure if the title makes any sense, but here is what I need.  This is my byte: ???????????????0F*E??ù?    ? I have already managed to get the values of this byte with this php snippet:  <?php $var = "???????????????0F*E??ù?";...
I'm not sure this is a programming question or more of a math problem, but since it's in the context of a javascript program I'm writing, I'm posting here.  I have an array of byte values from 0-255 (UInt8Array) re...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.