Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I don't know of standard procedures, but here are my thoughts:</p> <p>In general, I can think of two approaches to porting an existing software to either another language, use of another library, or any change of the such; with minimal structural change or with major structural change.</p> <p><strong>Minimal structural change</strong> means that you leave the structure of your program intact, and start replacing every single bit of it by its equivalent in the other library. For example, if porting from glut to SDL, you replacing the glut window creation with SDL's, keyboard handling with SDL's etc, all independently.</p> <p>This method is faster, in the sense that all the changes are small and local. You are also less likely to introduce bugs. The result may not be so efficient though, as the structure of the program is not originally designed for this new library.</p> <p><strong>Major structural change</strong> means that based on the new library, you rewrite a large part of the program that is dependent on that library. For example, if switching from C++'s STL to C's standard libraries, rewriting <code>string</code> with its equivalent in C that keeps allocating/freeing/copying doesn't make sense because your approach should be fundamentally different.</p> <p>This approach requires a lot more work but in the end will give you a much better quality.</p> <hr> <p>Back to your particular case, I'm not sure how different SDL 2 is from SDL 1.2, but my guess is it's not fundamentally different. Therefore, I believe the first method should work in your case. That is, you should work out the equivalents in SDL 2 of the stuff you did in SDL 1.2, and replace them in your code accordingly.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload