Click here to Skip to main content
16,007,809 members
Home / Discussions / C#
   

C#

 
GeneralRe: Mime Types Pin
hadad31-May-07 7:18
hadad31-May-07 7:18 
QuestionLarge Image Pixel problem Pin
R.Myers31-May-07 6:24
R.Myers31-May-07 6:24 
AnswerRe: Large Image Pixel problem Pin
Guffa31-May-07 8:14
Guffa31-May-07 8:14 
AnswerRe: Large Image Pixel problem Pin
Luc Pattyn31-May-07 9:29
sitebuilderLuc Pattyn31-May-07 9:29 
GeneralRe: Large Image Pixel problem Pin
R.Myers31-May-07 9:57
R.Myers31-May-07 9:57 
QuestionEndian Pin
lost in transition 31-May-07 5:42
lost in transition 31-May-07 5:42 
AnswerRe: Endian Pin
led mike31-May-07 6:02
led mike31-May-07 6:02 
AnswerRe: Endian Pin
Luc Pattyn31-May-07 9:41
sitebuilderLuc Pattyn31-May-07 9:41 
Hi,

I dont think mixing big-endian and little-endian data in a single file is a good idea.
If only one type of system is involved, convert the "wrong endian" data before storing
it; it different types of systems are involved, select one type, and let the systems
with the other convention do all the conversions every time.

Anyhow, you can change from one to the other with simple byte swapping
BTW the code is the same for either direction i.e. big2little and little2big
are no different.

The code can be based on byte extraction/insertion (using and, shift, or),
or on a union-like construct (using a struct with FieldOffsetAttribute).

Smile | :)


GeneralRe: Endian Pin
lost in transition 31-May-07 9:51
lost in transition 31-May-07 9:51 
GeneralRe: Endian Pin
Luc Pattyn31-May-07 10:03
sitebuilderLuc Pattyn31-May-07 10:03 
GeneralRe: Endian Pin
lost in transition 31-May-07 10:21
lost in transition 31-May-07 10:21 
GeneralRe: Endian Pin
Luc Pattyn31-May-07 10:51
sitebuilderLuc Pattyn31-May-07 10:51 
GeneralRe: Endian Pin
lost in transition 31-May-07 11:47
lost in transition 31-May-07 11:47 
GeneralRe: Endian Pin
Luc Pattyn31-May-07 12:00
sitebuilderLuc Pattyn31-May-07 12:00 
GeneralRe: Endian Pin
lost in transition 1-Jun-07 4:58
lost in transition 1-Jun-07 4:58 
GeneralRe: Endian Pin
Luc Pattyn1-Jun-07 6:14
sitebuilderLuc Pattyn1-Jun-07 6:14 
GeneralRe: Endian Pin
lost in transition 1-Jun-07 8:52
lost in transition 1-Jun-07 8:52 
GeneralRe: Endian Pin
Luc Pattyn1-Jun-07 10:08
sitebuilderLuc Pattyn1-Jun-07 10:08 
GeneralRe: Endian Pin
lost in transition 31-May-07 11:52
lost in transition 31-May-07 11:52 
GeneralRe: Endian Pin
Luc Pattyn31-May-07 12:05
sitebuilderLuc Pattyn31-May-07 12:05 
AnswerRe: Endian Pin
lost in transition 31-May-07 9:43
lost in transition 31-May-07 9:43 
QuestionPlease Help: ClickOnce Technology Pin
salman_syed_0131-May-07 4:14
salman_syed_0131-May-07 4:14 
AnswerPlease do not double post Pin
leckey31-May-07 4:38
leckey31-May-07 4:38 
AnswerRe: Please Help: ClickOnce Technology Pin
mikker_1232-Jun-07 17:08
mikker_1232-Jun-07 17:08 
QuestionLog4 Net SMS Appender Pin
Cape Town Developer31-May-07 4:04
Cape Town Developer31-May-07 4:04 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.