summaryrefslogtreecommitdiff
path: root/platform/flash/godot_flash.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2016-04-25 18:49:56 +0200
committerRémi Verschelde <rverschelde@gmail.com>2016-04-25 19:08:22 +0200
commitf368d380e708bd39589a309e2611b55306b78b3a (patch)
treecac7783b7d5da7d85d590f3f69ed942af386edf3 /platform/flash/godot_flash.cpp
parent82a725a3fd8033c87c2e15232bab6dd01e877710 (diff)
Drop obsolete WIP for Flash platform
It was apparently never fully functional and has not been maintained. Flash itself is nowadays clearly a deprecated technology, so there will not be further work on it. platform/javascript and the upcoming WebAssembly technologies should have a brighter future.
Diffstat (limited to 'platform/flash/godot_flash.cpp')
-rw-r--r--platform/flash/godot_flash.cpp80
1 files changed, 0 insertions, 80 deletions
diff --git a/platform/flash/godot_flash.cpp b/platform/flash/godot_flash.cpp
deleted file mode 100644
index 5e7d6214b8..0000000000
--- a/platform/flash/godot_flash.cpp
+++ /dev/null
@@ -1,80 +0,0 @@
-
-#include "main/main.h"
-#include "os_flash.h"
-#include <AS3/AS3.h>
-#include <Flash++.h>
-
-#include <stdio.h>
-
-using namespace AS3::ui;
-
-static int frames = 0;
-
-static OSFlash* os_flash = NULL;
-static uint64_t last_time = 0;
-
-static var frame(void* data, var args) {
-
- if (frames < 3) {
- uint64_t now = os_flash->get_ticks_usec();
- printf("enter frame %i, %f\n", frames, (now - last_time) / 1000000.0);
- last_time = now;
- };
- switch (frames) {
-
- case 0: {
- char* argv[] = {"-test", "gui", NULL};
- Main::setup("", 2, argv, false);
- ++frames;
- } break;
- case 1:
- Main::setup2();
- ++frames;
- break;
- case 2:
- Main::start();
- ++frames;
- break;
- default:
- os_flash->iterate();
- inline_as3("import GLS3D.*;\n"
- "GLAPI.instance.context.present();\n"
- : :
- );
- /*
- flash::display::Stage stage = internal::get_Stage();
- flash::display::Stage3D s3d = var(var(stage->stage3Ds)[0]);
- flash::display3D::Context3D ctx3d = s3d->context3D;
- ctx3d->present();
- */
- break;
- };
-
- return internal::_undefined;
-};
-
-static var context_error(void *arg, var as3Args) {
-
- printf("stage 3d error!\n");
-
- return internal::_undefined;
-};
-
-int main(int argc, char* argv[]) {
-
- printf("godot flash\n");
- os_flash = new OSFlash;
- printf("os\n");
-
- last_time = os_flash->get_ticks_usec();
-
- flash::display::Stage stage = internal::get_Stage();
- stage->scaleMode = flash::display::StageScaleMode::NO_SCALE;
- stage->align = flash::display::StageAlign::TOP_LEFT;
- stage->frameRate = 60;
-
- stage->addEventListener(flash::events::Event::ENTER_FRAME, Function::_new(frame, NULL));
-
- AS3_GoAsync();
-};
-