Login Action Required

The NinevehGL Forum uses a new concept of "socialized forum" or as we like to say "Tweet Forum".


Here is the deal:
  1. No new registration is required. Just sign in with your Twitter account and authorize the NinevehGL Forum.
  2. Once you’re in, you'll be able to "Follow a Thread", that means every time that thread receive a new post or update you'll receive a mention on your twitter.
  3. Besides, you can enable "Auto Share", then every new post and/or thread you make will be tweeted on your timeline. (By default, auto-share is enabled only for your threads)

Forum Rules:

1. We understand human comunication can become "hot" sometimes. So some insults and bad words ARE allowed. Just don't push too much being an asshole all the time.

2. SPAMMERS are not allowed. There are penalties for this kind of user and they can be banned forever.

3. You can report other users, if you judge necessary. An user reported many times by many people can also be banned forever. However you can also receive penalties for report deliberately for no apparent reason.

If there is a similar thread title, make sure the other one doesn't already have the answer you're looking for.

This forum uses the BBCode (Bulletin Board Code), here are some instructions:

Bold: [b]text[/b]
Italic: [i]text[/i]
Underline: [u]text[/u]

Code: [code]text[/code]
Quote:
[quote=@username]text[/quote]
[quote]text[/quote]

List:
[ul] [*]item [/ul]
[ol] [*]item [/ol]

URL:
[url]http://url.com[/url]
[url=http://url.com]text[/url]

Image:
[img]http://imageurl.com[/img]

Embed (videos, code, 3D):
[embed]http://url.com[/embed]

Welcome to the NinevehGL's world!
NinevehGL is a 3D engine forged with pure Obj-C.
Welcome to the
Forum!
Hello, Guest.

Your current vote:

You can change your vote many times. But it's still one single vote.

issue with get/save img with drawToData
Vote this thread:


@koolou_zeng

Posts: 4

NGLNewbie

Mon, Dec 23 2013


NSString *documentPath = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) objectAtIndex:0];

NSData *data = [_nglView drawToData:NGLImageFileTypePNG];
[data writeToFile:path atomically:YES]

I try to use the code to get a screenshot of nglview, but the image is blank.

how can i get a normal img of nglview?
0% like this - 0/0

@dineybomfim

Posts: 571

NGLAdmin

Tue, Dec 24 2013


In response to: @koolou_zeng

It's a bug with the current method. We'll fix it in the next release.
0% like this - 0/0

@yang5664

Posts: 16

NGLNewbie

Tue, Dec 24 2013


In response to: @koolou_zeng

you need in method of drawView() to do... => [nglView drawToImage]
and also must call it after [_camera drawCamera];

like this....

-(void)drawView{
...........

QCAR::Renderer::getInstance().end();
// Qualcomm disables the depth test internally, so we must enable it again.

glEnable(GL_DEPTH_TEST);
[_camera drawCamera];
if (_isScreenShot) {
[self stopCamera];
[_ivScreen setImage:[nglView drawToImage]]; //_ivScreen is UImageView
_isScreenShot = NO;
}
}

for me it's work...
100% like this - 1/1

@koolou_zeng

Posts: 4

NGLNewbie

Wed, Jan 15 2014


In response to: @yang5664

stopCamera ?

how to do that?
0% like this - 0/0

@koolou_zeng

Posts: 4

NGLNewbie

Wed, Jan 15 2014


In response to: @koolou_zeng

i use nglview.paused=YES to stop camera

and it works
0% like this - 0/0

@dineybomfim

Posts: 571

NGLAdmin

Wed, Jan 15 2014


In response to: @koolou_zeng

Yes, you're right.

You can pause the camera if you just want to make it temporary or completely release the camera if you don't need it any more.
0% like this - 0/0

@Momeks

Posts: 71

NGLSpecialist

Sat, Apr 12 2014


In response to: @koolou_zeng

did your problem solved ??
0% like this - 0/0

@Momeks

Posts: 71

NGLSpecialist

Sat, Apr 12 2014


In response to: @yang5664

I did your following method but did not worked :( !! it's strange my method works fine on my device but when I installed on the other devices no 3D image is captured !!!!!!! and the view is empty . STUPID BUG
0% like this - 0/0
Technology

NinevehGL is a 3D engine built right on top of OpenGL ES and it uses all the programmable pipeline power, making it easy for you to create great application with shaders.

Share on


Follow NinevehGL
Fastest way to contact us:

Copyright © 2011 db-in. All rights reserved.