[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [39840] trunk/blender/source/blender: fix for building without audaspace, since pepper merge

Campbell Barton ideasman42 at gmail.com
Thu Sep 1 11:46:07 CEST 2011


Revision: 39840
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=39840
Author:   campbellbarton
Date:     2011-09-01 09:46:07 +0000 (Thu, 01 Sep 2011)
Log Message:
-----------
fix for building without audaspace, since pepper merge

Modified Paths:
--------------
    trunk/blender/source/blender/blenkernel/intern/sound.c
    trunk/blender/source/blender/editors/sound/sound_ops.c

Modified: trunk/blender/source/blender/blenkernel/intern/sound.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/sound.c	2011-09-01 09:11:00 UTC (rev 39839)
+++ trunk/blender/source/blender/blenkernel/intern/sound.c	2011-09-01 09:46:07 UTC (rev 39840)
@@ -760,5 +760,17 @@
 float sound_sync_scene(struct Scene *UNUSED(scene)) { return 0.0f; }
 int sound_scene_playing(struct Scene *UNUSED(scene)) { return -1; }
 int sound_read_sound_buffer(struct bSound* UNUSED(sound), float* UNUSED(buffer), int UNUSED(length), float UNUSED(start), float UNUSED(end)) { return 0; }
+void sound_read_waveform(struct bSound* sound) { (void)sound; }
+void sound_init_main(struct Main *bmain) { (void)bmain; }
+void sound_set_cfra(int cfra) { (void)cfra; }
+void sound_update_sequencer(struct Main* main, struct bSound* sound) { (void)main; (void)sound; }
+void sound_update_scene(struct Scene* scene) { (void)scene; }
+void sound_update_scene_sound(void* handle, struct bSound* sound) { (void)handle; (void)sound; }
+void sound_update_scene_listener(struct Scene *scene) { (void)scene; }
+void sound_update_fps(struct Scene *scene) { (void)scene; }
+void sound_set_scene_sound_volume(void* handle, float volume, char animated) { (void)handle; (void)volume; (void)animated; }
+void sound_set_scene_sound_pan(void* handle, float pan, char animated) { (void)handle; (void)pan; (void)animated; }
+void sound_set_scene_volume(struct Scene *scene, float volume) { (void)scene; (void)volume; }
+void sound_set_scene_sound_pitch(void* handle, float pitch, char animated) { (void)handle; (void)pitch; (void)animated; }
 
 #endif // WITH_AUDASPACE

Modified: trunk/blender/source/blender/editors/sound/sound_ops.c
===================================================================
--- trunk/blender/source/blender/editors/sound/sound_ops.c	2011-09-01 09:11:00 UTC (rev 39839)
+++ trunk/blender/source/blender/editors/sound/sound_ops.c	2011-09-01 09:46:07 UTC (rev 39840)
@@ -221,6 +221,7 @@
 
 static int mixdown_exec(bContext *C, wmOperator *op)
 {
+#ifdef WITH_AUDASPACE
 	char path[FILE_MAX];
 	char filename[FILE_MAX];
 	Scene *scene;
@@ -254,7 +255,10 @@
 		BKE_report(op->reports, RPT_ERROR, result);
 		return OPERATOR_CANCELLED;
 	}
-
+#else // WITH_AUDASPACE
+	(void)C;
+	(void)op;
+#endif // WITH_AUDASPACE
 	return OPERATOR_FINISHED;
 }
 
@@ -278,6 +282,7 @@
 	);
 }
 
+#ifdef WITH_AUDASPACE
 static void mixdown_draw(bContext *C, wmOperator *op)
 {
 	static EnumPropertyItem pcm_format_items[] = {
@@ -429,9 +434,11 @@
 	/* main draw call */
 	uiDefAutoButsRNA(layout, &ptr, mixdown_draw_check_prop, '\0');
 }
+#endif // WITH_AUDASPACE
 
 void SOUND_OT_mixdown(wmOperatorType *ot)
 {
+#ifdef WITH_AUDASPACE
 	static EnumPropertyItem format_items[] = {
 		{AUD_FORMAT_U8, "U8", 0, "U8", "8 bit unsigned"},
 		{AUD_FORMAT_S16, "S16", 0, "S16", "16 bit signed"},
@@ -469,6 +476,8 @@
 		{AUD_CODEC_VORBIS, "VORBIS", 0, "Vorbis", "Xiph.Org Vorbis Codec"},
 		{0, NULL, 0, NULL, NULL}};
 
+#endif // WITH_AUDASPACE
+
 	/* identifiers */
 	ot->name= "Mixdown";
 	ot->description= "Mixes the scene's audio to a sound file";
@@ -477,18 +486,22 @@
 	/* api callbacks */
 	ot->exec= mixdown_exec;
 	ot->invoke= mixdown_invoke;
+
+#ifdef WITH_AUDASPACE
 	ot->ui= mixdown_draw;
-
+#endif
 	/* flags */
 	ot->flag= OPTYPE_REGISTER;
 
 	/* properties */
 	WM_operator_properties_filesel(ot, FOLDERFILE|SOUNDFILE, FILE_SPECIAL, FILE_SAVE, WM_FILESEL_FILEPATH);
+#ifdef WITH_AUDASPACE
 	RNA_def_int(ot->srna, "accuracy", 1024, 1, 16777216, "Accuracy", "Sample accuracy. Important for animation data. The lower the value, the more accurate.", 1, 16777216);
 	RNA_def_enum(ot->srna, "container", container_items, AUD_CONTAINER_FLAC, "Container", "File format");
 	RNA_def_enum(ot->srna, "codec", codec_items, AUD_CODEC_FLAC, "Codec", "Audio Codec");
 	RNA_def_enum(ot->srna, "format", format_items, AUD_FORMAT_S16, "Format", "Sample format");
 	RNA_def_int(ot->srna, "bitrate", 192, 32, 512, "Bitrate", "Bitrate in kbit/s", 32, 512);
+#endif // WITH_AUDASPACE
 }
 
 /* ******************************************************* */




More information about the Bf-blender-cvs mailing list