Commit 5429d344 authored by Simon Morlat's avatar Simon Morlat

remove all TARGET_OS_IPHONE

parent a9aa5aba
......@@ -57,7 +57,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#endif
#include <AudioToolbox/AudioToolbox.h>
#if !TARGET_OS_IPHONE
#ifndef __ios
#include <CoreAudio/AudioHardware.h>
#endif
......@@ -76,7 +76,7 @@ static float gain_volume_out=1.0;
static bool gain_changed_in = true;
static bool gain_changed_out = true;
#if TARGET_OS_IPHONE
#ifdef __ios
#define CFStringRef void *
#define CFRelease(A) {}
#define CFStringGetCString(A, B, LEN, encoding) {}
......@@ -253,7 +253,7 @@ static void show_format(char *name,
static void aqcard_detect(MSSndCardManager * m)
{
#if TARGET_OS_IPHONE
#ifdef __ios
AudioStreamBasicDescription deviceFormat;
memset(&deviceFormat, 0, sizeof(AudioStreamBasicDescription));
......
......@@ -207,7 +207,6 @@ static int dtmfgen_stop(MSFilter *f, void *arg){
static int dtmfgen_set_rate(MSFilter *f, void *arg){
DtmfGenState *s=(DtmfGenState*)f->data;
s->rate=*((int*)arg);
return 0;
}
......
......@@ -395,7 +395,7 @@ static MSScalerContext *ff_create_swscale_context(int src_w, int src_h, MSPixFmt
int ff_flags=0;
MSFFScalerContext *ctx=ms_new(MSFFScalerContext,1);
ctx->src_h=src_h;
#if (TARGET_OS_IPHONE)
#if __arm__
ff_flags|=SWS_FAST_BILINEAR;
#else
if (flags & MS_SCALER_METHOD_BILINEAR)
......
......@@ -15,7 +15,7 @@
#ifndef SHADERS_H
#define SHADERS_H
#ifdef TARGET_OS_IPHONE
#ifdef __ios
#include <OpenGLES/ES2/gl.h>
#include <OpenGLES/ES2/glext.h>
#else
......
......@@ -27,13 +27,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#include "mediastreamer2/msrtp.h"
#include "mediastreamer2/msvideoout.h"
#include "mediastreamer2/msextdisplay.h"
#ifndef TARGET_OS_IPHONE
#include <ortp/zrtp.h>
#endif
#ifndef TARGET_OS_IPHONE
#define TARGET_OS_IPHONE 0
#endif
extern RtpSession * create_duplex_rtpsession( int locport, bool_t ipv6);
......@@ -208,7 +205,7 @@ static void choose_display_name(VideoStream *stream){
stream->display_name=ms_strdup("MSAndroidDisplay");
#elif defined (HAVE_X11_EXTENSIONS_XV_H)
stream->display_name=ms_strdup("MSX11Video");
#elif defined (TARGET_OS_IPHONE)
#elif defined(__ios)
stream->display_name=ms_strdup("IOSDisplay");
#else
stream->display_name=ms_strdup("MSVideoOut");
......
......@@ -45,8 +45,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#ifdef __APPLE__
#include <CoreFoundation/CFRunLoop.h>
#endif
#if TARGET_OS_IPHONE || defined (ANDROID)
#if defined(__ios) || defined (ANDROID)
#ifdef __ios
#import <UIKit/UIKit.h>
#endif
extern void ms_set_video_stream(VideoStream* video);
#ifdef HAVE_X264
extern void libmsx264_init();
......@@ -194,7 +196,7 @@ int main(int argc, char * argv[]) {
#if TARGET_OS_MACOSX
CFRunLoopRun();
return 0;
#elif TARGET_OS_IPHONE
#elif defined(__ios)
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
int value = UIApplicationMain(0, nil, nil, nil);
[pool release];
......@@ -435,7 +437,7 @@ void setup_media_streams(MediastreamDatas* args) {
}
#if TARGET_OS_IPHONE || defined (ANDROID)
#if defined(__ios) || defined(ANDROID)
#if defined (HAVE_X264) && defined (VIDEO_ENABLED)
libmsx264_init(); /*no plugin on IOS*/
#endif
......@@ -543,14 +545,12 @@ void setup_media_streams(MediastreamDatas* args) {
}
}
#if TARGET_OS_IPHONE
if (args->zrtp_id != NULL) {
OrtpZrtpParams params;
params.zid=args->zrtp_id;
params.zid_file=args->zrtp_secrets;
audio_stream_enable_zrtp(args->audio,&params);
}
#endif
args->session=args->audio->session;
}
......@@ -577,7 +577,7 @@ void setup_media_streams(MediastreamDatas* args) {
#endif
video_stream_set_sent_video_size(args->video,args->vs);
video_stream_use_preview_video_window(args->video,args->two_windows);
#if TARGET_OS_IPHONE
#ifdef __ios
NSBundle* myBundle = [NSBundle mainBundle];
const char* nowebcam = [[myBundle pathForResource:@"nowebcamCIF"ofType:@"jpg"] cStringUsingEncoding:[NSString defaultCStringEncoding]];
ms_static_image_set_default_image(nowebcam);
......@@ -650,10 +650,9 @@ void run_interactive_loop(MediastreamDatas* args) {
void run_non_interactive_loop(MediastreamDatas* args) {
rtp_session_register_event_queue(args->session,args->q);
#if TARGET_OS_IPHONE && defined(VIDEO_ENABLED)
#if defined(_iOS) && defined(VIDEO_ENABLED)
ms_set_video_stream(args->video); /*for IOS*/
#endif
#endif
while(cond)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment