Skip to main content
replaced http://gamedev.stackexchange.com/ with https://gamedev.stackexchange.com/
Source Link

Since one can use C++ libraries in Objective-C also, there's actually no need to create special Objective-C header files.

Box2D for example is a pure C++ physics engine but is used in a lot of games, even ones written in Objective-C.

The only caveat (for developers using your library) is that

you still need to instruct the compiler to build all files that use C++ headers as Objective-C++ rather than Objective-C.

(as per SamSam's comment)

Since one can use C++ libraries in Objective-C also, there's actually no need to create special Objective-C header files.

Box2D for example is a pure C++ physics engine but is used in a lot of games, even ones written in Objective-C.

The only caveat (for developers using your library) is that

you still need to instruct the compiler to build all files that use C++ headers as Objective-C++ rather than Objective-C.

(as per Sam's comment)

Since one can use C++ libraries in Objective-C also, there's actually no need to create special Objective-C header files.

Box2D for example is a pure C++ physics engine but is used in a lot of games, even ones written in Objective-C.

The only caveat (for developers using your library) is that

you still need to instruct the compiler to build all files that use C++ headers as Objective-C++ rather than Objective-C.

(as per Sam's comment)

Since one can use C++ libraries in Objective-C also, there's actually no need to create special Objective-C header files.

Box2D for example is a pure C++ physics engine but is used in a lot of games, even ones written in Objective-C.

The only caveat (for developers using your library) is that

you still need to instruct the compiler to build all files that use C++ headers as Objective-C++ rather than Objective-C.

(as per Sam's comment)

Since one can use C++ libraries in Objective-C also, there's actually no need to create special Objective-C header files.

Box2D for example is a pure C++ physics engine but is used in a lot of games, even ones written in Objective-C.

Since one can use C++ libraries in Objective-C also, there's actually no need to create special Objective-C header files.

Box2D for example is a pure C++ physics engine but is used in a lot of games, even ones written in Objective-C.

The only caveat (for developers using your library) is that

you still need to instruct the compiler to build all files that use C++ headers as Objective-C++ rather than Objective-C.

(as per Sam's comment)

Source Link
bummzack
  • 22.7k
  • 5
  • 64
  • 87

Since one can use C++ libraries in Objective-C also, there's actually no need to create special Objective-C header files.

Box2D for example is a pure C++ physics engine but is used in a lot of games, even ones written in Objective-C.