Saving AVI with Overlay.. slow.. any workaround​?

Hello there
I couldnt find any clear answers so I'll just ask here
My application needs to do the following:
1 - grab an image from camera
2 - add overlay (overlay is consisting of dynamic items)
3 - view image w/overlay in a external window
4 - save AVI with overlay
The most importent thing is that the external window showing the overlay and picture has a high refresh rate. Below is the code for this: (wow it got quite huge.. Im sorry about that.,.)
First, it grabs an image from the camera. This grab function removes any overlay that was there before (blæh.). Second a clear error is used (Im lazy and havent included errorhandling.. yet), third, each 200ms (the loop runs at 20 ms) the dynamic overlay items are updated on my own overlay picture. The reason I use an own picture with the overlay is that I want to minimize redrawing of static elements on the overlay. Fourth - copy the overlay from my static overlay picture to the grabbed image. Fifth - show the picture in an external window. Sixth - Set the IMAQ reference to a func. global.
This loop runs perfectly. The reason for not using "merge overlay" here is that is goes to slow and messes with the update frequency..
Second, the loop that saves the AVI file:
First - the func global is red with the IMAQ ref that has both the grabbed image and the overlay.
Second - This IMAQ pic is duplicated. Why? well, if the merge overlay is going to merge the original IMAQ picture, it would somehow slow up the external display (and that gets choppy) (althrough, beats me why this happends)
Third - The overlay is merged
fourth - The merged overlay is saved.
Now what happends is that this saving is just going way to slow, (but by doing it the way I did, it doesnt messes with the update frequency of the external display) And it all has something to do with the merge overlay. If I disable the merging everything is fine - but the video does not show any overlay.
Below is an example of how the overlay may look like:
Does anyone have any clues how I can further improve this to be faster? my AVI file gets like mega choppy when merging overlays like the picture above!
Solved!
Go to Solution.

BlueCheese, thanks a lot.
I understand it is difficult to read. The camera application stuff is only a smaller part of a larger software
FYI: The reason why I used one loop for aquisition & showing, and one for saving (and merging) was simply that if I put the merging in the aquisation loop, it slows it down significantly and the poor operator who looks at the camera picture w/overlay would grow tired of that laggy stuff. So I needed to handled aquisation w/overlay in one loop, and saving/merging in another.
It perfectly makes sense what you said, and yes, this solves the flickering in the AVI. However logically, the performance dropped a bit to the ext. display due to that the copy function was introduced in the aquire loop, and created a bit longer lag there. Without overlay you wont notice, but when the dynamic overlay gets updated its noticed - I then introduced wait on multiplum in the update case, due to that previous using the Queue timeout (20ms) the total time would be a lot higher since the copy function is used in addition the total aq time would be around 30-40 ms I guess (or more) each time the update dynamic overlay function kicks in. A possible solution would be to put the overlay updating in an own loop,and introducing another paralell case (and two more IMAQ picture refs) but I hope to avoid this due to that the compexity increases. I will try to see if I can tune in the timers, however they are depended on the amount of overlay that gets drawn. Since the user can draw and create its own overlay (the software will be used on many sites) I have no clue what they will configure individually.
The AVI save loop now does not have any flickering, and Im able to save to file with approx 5 frames per second. Going higher results in that the copy function & merge overlay function, in addition save to AVI would consume more time and it not able to save to AVI with the faster frame rate. I will try and see how much time that case uses, althrough again - its depended on how large the overlay is.
I'll leave this open for some days in case someone sees something else (or that I used the wrong strategy) that could be done to increase performance, if not I'll mark your comment as a solution and try to live with the performance issue.

Similar Messages

  • Firefox 3.6.9 / Windows 7 will not print using font specified with @font-face - any workarounds?

    I've seen a few mentions of this problem around the interwebs, but can't find a resolution. I used [http://www.fontsquirrel.com/fontface/generator fontsquirrel's font-face generator] to prepare different versions of a font for cross-browser display. Screen presentation in almost all browsers is fine, and almost all browsers print the embedded font as well - except for Firefox/PC (3.6.9/Windows 7).
    I have tried inline styles, styles inside of the head, and external stylesheets, all with and without media type print. What can I do?

    Hi John,
    Can u try the work around mentioned in the below link
    http://notsomany.wordpress.com/2010/03/30/jinitiator-working-on-windows-7/
    Also some times IE8 can block the webutil_file_transfer.
    AS_to_Client if "protected mode" is ON for the security zone your forms url is in (look in the statusbar in IE ->
    internet, trusted site, ... -> protected mode: On/Off)
    Regards
    Fabian

  • Saving Binary Image with Overlay?

    Hi
    I'm having some issues saving an image with overlay information. I'm using IMAQ Find Circles to measure the radii of holes in a binary image. The hole data is then used with IMAQ Overlay Oval, to draw on ovals to highlight the circles detected. Works fine and the image is shown as expected in the image output on screen, pallette is set to binary. (See second image of 3, below)
    When I try and save the image to PNG I just get a blank (black) image. If I use the IMAQ Merge Overlay tool, I just get the green circles on the black (see last image of 3 below). Is there something I'm missing with pallettes/merging? Any help much appreciated. Snapshot of (messy) code attached.
    Solved!
    Go to Solution.
    Attachments:
    forum2.PNG ‏47 KB

    The problem is the binary image is all zeroes and ones.  A normal image goes up to 255, so a value of 1 looks black.
    One solution is to multiply the binary image by 255, which makes the image black and white.
    Bruce
    Bruce Ammons
    Ammons Engineering

  • My MacBook Pro (Retina, Mid 2012) is too slow after installing Yosemite version 10.10.1. All programs take for ever to load especially Safari and even chrome. I regret upgrading to yosemite, it was all fine with Maverick. Any suggestions ? ThankYou

    My MacBook Pro (Retina, Mid 2012) is too slow after installing Yosemite version 10.10.1. All programs take for ever to load especially Safari and even chrome. I regret upgrading to yosemite, it was all fine with Maverick. Any suggestions ? ThankYou

    1. This procedure is a diagnostic test. It changes nothing, for better or worse, and therefore will not, in itself, solve the problem. But with the aid of the test results, the solution may take a few minutes, instead of hours or days.
    Don't be put off by the complexity of these instructions. The process is much less complicated than the description. You do harder tasks with the computer all the time.
    2. If you don't already have a current backup, back up all data before doing anything else. The backup is necessary on general principle, not because of anything in the test procedure. Backup is always a must, and when you're having any kind of trouble with the computer, you may be at higher than usual risk of losing data, whether you follow these instructions or not.
    There are ways to back up a computer that isn't fully functional. Ask if you need guidance.
    3. Below are instructions to run a UNIX shell script, a type of program. As I wrote above, it changes nothing. It doesn't send or receive any data on the network. All it does is to generate a human-readable report on the state of the computer. That report goes nowhere unless you choose to share it. If you prefer, you can act on it yourself without disclosing the contents to me or anyone else.
    You should be wondering whether you can believe me, and whether it's safe to run a program at the behest of a stranger. In general, no, it's not safe and I don't encourage it.
    In this case, however, there are a couple of ways for you to decide whether the program is safe without having to trust me. First, you can read it. Unlike an application that you download and click to run, it's transparent, so anyone with the necessary skill can verify what it does.
    You may not be able to understand the script yourself. But variations of the script have been posted on this website thousands of times over a period of years. The site is hosted by Apple, which does not allow it to be used to distribute harmful software. Any one of the millions of registered users could have read the script and raised the alarm if it was harmful. Then I would not be here now and you would not be reading this message.
    Nevertheless, if you can't satisfy yourself that these instructions are safe, don't follow them. Ask for other options.
    4. Here's a summary of what you need to do, if you choose to proceed:
    ☞ Copy a line of text in this window to the Clipboard.
    ☞ Paste into the window of another application.
    ☞ Wait for the test to run. It usually takes a few minutes.
    ☞ Paste the results, which will have been copied automatically, back into a reply on this page.
    The sequence is: copy, paste, wait, paste again. You don't need to copy a second time. Details follow.
    5. You may have started the computer in "safe" mode. Preferably, these steps should be taken in “normal” mode, under the conditions in which the problem is reproduced. If the system is now in safe mode and works well enough in normal mode to run the test, restart as usual. If you can only test in safe mode, do that.
    6. If you have more than one user, and the one affected by the problem is not an administrator, then please run the test twice: once while logged in as the affected user, and once as an administrator. The results may be different. The user that is created automatically on a new computer when you start it for the first time is an administrator. If you can't log in as an administrator, test as the affected user. Most personal Macs have only one user, and in that case this section doesn’t apply. Don't log in as root.
    7. The script is a single long line, all of which must be selected. You can accomplish this easily by triple-clicking anywhere in the line. The whole line will highlight, though you may not see all of it in the browser window, and you can then copy it. If you try to select the line by dragging across the part you can see, you won't get all of it.
    Triple-click anywhere in the line of text below on this page to select it:
    PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/libexec;clear;cd;p=(Software Hardware Memory Diagnostics Power FireWire Thunderbolt USB Fonts SerialATA 4 1000 25 5120 KiB/s 1024 85 \\b%% 20480 1 MB/s 25000 ports ' com.clark.\* \*dropbox \*genieo\* \*GoogleDr\* \*k.AutoCAD\* \*k.Maya\* vidinst\* ' DYLD_INSERT_LIBRARIES\ DYLD_LIBRARY_PATH -86 "` route -n get default|awk '/e:/{print $2}' `" 25 N\\/A down up 102400 25600 recvfrom sendto CFBundleIdentifier 25 25 25 1000 MB ' com.adobe.AAM.Updater-1.0 com.adobe.AAM.Updater-1.0 com.adobe.AdobeCreativeCloud com.adobe.CS4ServiceManager com.adobe.CS5ServiceManager com.adobe.fpsaud com.adobe.SwitchBoard com.adobe.SwitchBoard com.apple.aelwriter com.apple.AirPortBaseStationAgent com.apple.FolderActions.enabled com.apple.installer.osmessagetracing com.apple.mrt.uiagent com.apple.ReportCrash.Self com.apple.rpmuxd com.apple.SafariNotificationAgent com.apple.usbmuxd com.citrixonline.GoToMeeting.G2MUpdate com.google.keystone.agent com.google.keystone.daemon com.microsoft.office.licensing.helper com.oracle.java.Helper-Tool com.oracle.java.JavaUpdateHelper com.oracle.java.JavaUpdateHelper org.macosforge.xquartz.privileged_startx org.macosforge.xquartz.privileged_startx org.macosforge.xquartz.startx ' ' 879294308 4071182229 461455494 3627668074 1083382502 1274181950 1855907737 2758863019 1848501757 464843899 3694147963 1233118628 2456546649 2806998573 2778718105 2636415542 842973933 2051385900 3301885676 891055588 998894468 695903914 1443423563 4136085286 523110921 2883943871 3873345487 ' 51 5120 files );N5=${#p[@]};p[N5]=` networksetup -listnetworkserviceorder|awk ' NR>1 { sub(/^\([0-9]+\) /,"");n=$0;getline;} $NF=="'${p[26]}')" { sub(/.$/,"",$NF);print n;exit;} ' `;f=('\n%s: %s\n' '\n%s\n\n%s\n' '\nRAM details\n%s\n' %s\ %s '%s\n-\t%s\n' );S0() { echo ' { q=$NF+0;$NF="";u=$(NF-1);$(NF-1)="";gsub(/^ +| +$/,"");if(q>='${p[$1]}') printf("%s (UID %s) is using %s '${p[$2]}'",$0,u,q);} ';};s=(' s/[0-9A-Za-z._]+@[0-9A-Za-z.]+\.[0-9A-Za-z]{2,4}/EMAIL/g;/faceb/s/(at\.)[^.]+/\1NAME/g;/\/Shared/!s/(\/Users\/)[^ /]+/\1USER/g;s/[-0-9A-Fa-f]{22,}/UUID/g;' ' s/^ +//;/de: S|[nst]:/p;' ' {sub(/^ +/,"")};/er:/;/y:/&&$2<'${p[10]} ' 1s/://;3,6d;/[my].+:/d;s/^ {4}//;H;${ g;s/\n$//;/s: (E[^m]|[^EO])|x([^08]|02[^F]|8[^0])/p;} ' ' 5h;6{ H;g;/P/!p;} ' ' ($1~/^Cy/&&$3>'${p[11]}')||($1~/^Cond/&&$2!~/^N/) ' ' /:$/{ N;/:.+:/d;s/ *://;b0'$'\n'' };/^ *(V.+ [0N]|Man).+ /{ s/ 0x.... //;s/[()]//g;s/(.+: )(.+)/ (\2)/;H;};$b0'$'\n'' d;:0'$'\n'' x;s/\n\n//;/Apple[ ,]|Genesy|Intel|SMSC/d;s/\n.*//;/\)$/p;' ' s/^.*C/C/;H;${ g;/No th|pms/!p;} ' '/= [^GO]/p' '{$1=""};1' ' /Of/!{ s/^.+is |\.//g;p;} ' ' $0&&!/ / { n++;print;} END { if(n<10) print "com.apple.";} ' ' { sub(/ :/,"");print|"tail -n'${p[12]}'";} ' ' NR==2&&$4<='${p[13]}' { print $4;} ' ' END { $2/=256;if($2>='${p[15]}') print int($2) } ' ' NR!=13{next};{sub(/[+-]$/,"",$NF)};'"`S0 21 22`" 'NR!=2{next}'"`S0 37 17`" ' NR!=5||$8!~/[RW]/{next};{ $(NF-1)=$1;$NF=int($NF/10000000);for(i=1;i<=3;i++){$i="";$(NF-1-i)="";};};'"`S0 19 20`" 's:^:/:p' '/\.kext\/(Contents\/)?Info\.plist$/p' 's/^.{52}(.+) <.+/\1/p' ' /Launch[AD].+\.plist$/ { n++;print;} END { if(n<200) print "/System/";} ' '/\.xpc\/(Contents\/)?Info\.plist$/p' ' NR>1&&!/0x|\.[0-9]+$|com\.apple\.launchctl\.(Aqua|Background|System)$/ { print $3;} ' ' /\.(framew|lproj)|\):/d;/plist:|:.+(Mach|scrip)/s/:[^:]+//p ' '/^root$/p' ' !/\/Contents\/.+\/Contents|Applic|Autom|Frameworks/&&/Lib.+\/Info.plist$/ { n++;print;} END { if(n<1100) print "/System/";} ' '/^\/usr\/lib\/.+dylib$/p' ' /Temp|emac/{next};/(etc|Preferences|Launch[AD].+)\// { sub(".(/private)?","");n++;print;} END { split("'"${p[41]}"'",b);split("'"${p[42]}"'",c);for(i in b) print b[i]".plist\t"c[i];if(n<500) print "Launch";} ' ' /\/(Contents\/.+\/Contents|Frameworks)\/|\.wdgt\/.+\.([bw]|plu)/d;p;' 's/\/(Contents\/)?Info.plist$//;p' ' { gsub("^| |\n","\\|\\|kMDItem'${p[35]}'=");sub("^...."," ") };1 ' p '{print $3"\t"$1}' 's/\'$'\t''.+//p' 's/1/On/p' '/Prox.+: [^0]/p' '$2>'${p[43]}'{$2=$2-1;print}' ' BEGIN { i="'${p[26]}'";M1='${p[16]}';M2='${p[18]}';M3='${p[31]}';M4='${p[32]}';} !/^A/{next};/%/ { getline;if($5<M1) a="user "$2"%, system "$4"%";} /disk0/&&$4>M2 { b=$3" ops/s, "$4" blocks/s";} $2==i { if(c) { d=$3+$4+$5+$6;next;};if($4>M3||$6>M4) c=int($4/1024)" in, "int($6/1024)" out";} END { if(a) print "CPU: "a;if(b) print "I/O: "b;if(c) print "Net: "c" (KiB/s)";if(d) print "Net errors: "d" packets/s";} ' ' /r\[0\] /&&$NF!~/^1(0|72\.(1[6-9]|2[0-9]|3[0-1])|92\.168)\./ { print $NF;exit;} ' ' !/^T/ { printf "(static)";exit;} ' '/apsd|BKAg|OpenD/!s/:.+//p' ' (/k:/&&$3!~/(255\.){3}0/ )||(/v6:/&&$2!~/A/ ) ' ' $1~"lR"&&$2<='${p[25]}';$1~"li"&&$3!~"wpa2";' ' BEGIN { FS=":";p="uniq -c|sed -E '"'s/ +\\([0-9]+\\)\\(.+\\)/\\\2 x\\\1/;s/x1$//'"'";} { n=split($3,a,".");sub(/_2[01].+/,"",$3);print $2" "$3" "a[n]$1|p;b=b$1;} END { close(p);if(b) print("\n\t* Code injection");} ' ' NR!=4{next} {$NF/=10240} '"`S0 27 14`" ' END { if($3~/[0-9]/)print$3;} ' ' BEGIN { L='${p[36]}';} !/^[[:space:]]*(#.*)?$/ { l++;if(l<=L) f=f"\n   "$0;} END { F=FILENAME;if(!F) exit;if(!f) f="\n   [N/A]";"cksum "F|getline C;split(C, A);C="checksum "A[1];"file -b "F|getline T;if(T!~/^(AS.+ (En.+ )?text(, with v.+)?$|(Bo|PO).+ sh.+ text ex|XM)/) F=F" ("T", "C")";else F=F" ("C")";printf("\nContents of %s\n%s\n",F,f);if(l>L) printf("\n   ...and %s more line(s)\n",l-L);} ' ' s/^ ?n...://p;s/^ ?p...:/-'$'\t''/p;' 's/0/Off/p' ' END{print NR} ' ' /id: N|te: Y/{i++} END{print i} ' ' / / { print "'"${p[28]}"'";exit;};1;' '/ en/!s/\.//p' ' NR!=13{next};{sub(/[+-M]$/,"",$NF)};'"`S0 39 40`" ' $10~/\(L/&&$9!~"localhost" { sub(/.+:/,"",$9);print $1": "$9|"sort|uniq";} ' '/^ +r/s/.+"(.+)".+/\1/p' 's/(.+\.wdgt)\/(Contents\/)?Info\.plist$/\1/p' 's/^.+\/(.+)\.wdgt$/\1/p' ' /l: /{ /DVD/d;s/.+: //;b0'$'\n'' };/s: /{ /V/d;s/^ */- /;H;};$b0'$'\n'' d;:0'$'\n'' x;/APPLE [^:]+$/d;p;' ' /^find: /d;p;' "`S0 44 45`" ' BEGIN{FS="= "} /Path/{print $2} ' ' /^ *$/d;s/^ */   /;' ' s/^.+ |\(.+\)$//g;p ' '/\.(appex|pluginkit)\/Contents\/Info\.plist$/p' ' /2/{print "WARN"};/4/{print "CRITICAL"};' ' /EVHF|MACR|^s/d;s/^.+: //p;' );c1=(system_profiler pmset\ -g nvram fdesetup find syslog df vm_stat sar ps crontab iotop top pkgutil 'PlistBuddy 2>&1 -c "Print' whoami cksum kextstat launchctl smcDiagnose sysctl\ -n defaults\ read stat lsbom mdfind ' for i in ${p[24]};do ${c1[18]} ${c2[27]} $i;done;' pluginkit scutil dtrace profiles sed\ -En awk /S*/*/P*/*/*/C*/*/airport networksetup mdutil lsof test osascript\ -e );c2=(com.apple.loginwindow\ LoginHook '" /L*/P*/loginw*' "'tell app \"System Events\" to get properties of login items'|tr , \\\n" 'L*/Ca*/com.ap*.Saf*/E*/* -d 1 -name In*t -exec '"${c1[14]}"' :CFBundleDisplayName" {} \;|sort|uniq' '~ $TMPDIR.. \( -flags +sappnd,schg,uappnd,uchg -o ! -user $UID -o ! -perm -600 \)' '.??* -path .Trash -prune -o -type d -name *.app -print -prune' :${p[35]}\" :Label\" '{/,}L*/{Con,Pref}* -type f ! -size 0 -name *.plist -exec plutil -s {} \;' "-f'%N: %l' Desktop L*/Keyc*" therm sysload boot-args status " -F '\$Time \$(RefProc): \$Message' -k Sender Req 'fsev|kern|launchd' -k RefProc Rne 'Aq|WebK' -k Message Rne 'Goog|ksadm|probe|Roame|SMC:|smcD|sserti|suhel| VALI|ver-r|xpma' -k Message Req 'abn|bad |Beac|caug|corru|dead[^bl]|FAIL|fail|GPU |hfs: Ru|inval|jnl:|last value [1-9]|NVDA\(|pagin|proc: t|Roamed|rror|SL|TCON|Throttli|tim(ed? ?|ing )o|WARN' " '-du -n DEV -n EDEV 1 10' 'acrx -o comm,ruid,%cpu' '-t1 10 1' '-f -pfc /var/db/r*/com.apple.*.{BS,Bas,Es,J,OSXU,Rem,up}*.bom' '{/,}L*/Lo*/Diag* -type f -regex .\*[cght] ! -name .?\* ! -name \*ag \( -exec grep -lq "^Thread c" {} \; -exec printf \* \; -o -true \) -execdir stat -f:%Sc:%N -t%F {} \;|sort -t: -k2 |tail -n'${p[38]} '/S*/*/Ca*/*xpc* >&- ||echo No' '-L /{S*/,}L*/StartupItems -type f -exec file {} +' '-L /S*/L*/{C*/Sec*A,Ex}* {/,}L*/{A*d,Ca*/*/Ex,Co{mpon,reM},Ex,In{p,ter},iTu*/*P,Keyb,Mail/B,Pr*P,Qu*T,Scripti,Sec,Servi,Spo,Widg}* -path \\*s/Resources -prune -o -type f -name Info.plist' '/usr/lib -type f -name *.dylib' `awk "${s[31]}"<<<${p[23]}` "/e*/{auto,{cron,fs}tab,hosts,{[lp],sy}*.conf,mach_i*/*,pam.d/*,ssh{,d}_config,*.local} {,/usr/local}/etc/periodic/*/* /L*/P*{,/*}/com.a*.{Bo,sec*.ap}*t {/S*/,/,}L*/Lau*/*t .launchd.conf" list getenv /Library/Preferences/com.apple.alf\ globalstate --proxy '-n get default' -I --dns -getdnsservers\ "${p[N5]}" -getinfo\ "${p[N5]}" -P -m\ / '' -n1 '-R -l1 -n1 -o prt -stats command,uid,prt' '--regexp --only-files --files com.apple.pkg.*|sort|uniq' -kl -l -s\ / '-R -l1 -n1 -o mem -stats command,uid,mem' '+c0 -i4TCP:0-1023' com.apple.dashboard\ layer-gadgets '-d /L*/Mana*/$USER&&echo On' '-app Safari WebKitDNSPrefetchingEnabled' "+c0 -l|awk '{print(\$1,\$3)}'|sort|uniq -c|sort -n|tail -1|awk '{print(\$2,\$3,\$1)}'" -m 'L*/{Con*/*/Data/L*/,}Pref* -type f -size 0c -name *.plist.???????|wc -l' kern.memorystatus_vm_pressure_level '3>&1 >&- 2>&3' " -F '\$Time \$Message' -k Sender kernel -k Message CSeq 'n Cause: -' " );N1=${#c2[@]};for j in {0..9};do c2[N1+j]=SP${p[j]}DataType;done;N2=${#c2[@]};for j in 0 1;do c2[N2+j]="-n ' syscall::'${p[33+j]}':return { @out[execname,uid]=sum(arg0) } tick-10sec { trunc(@out,1);exit(0);} '";done;l=(Restricted\ files Hidden\ apps 'Elapsed time (s)' POST Battery Safari\ extensions Bad\ plists 'High file counts' User Heat System\ load boot\ args FileVault Diagnostic\ reports Log 'Free space (MiB)' 'Swap (MiB)' Activity 'CPU per process' Login\ hook 'I/O per process' Mach\ ports kexts Daemons Agents XPC\ cache Startup\ items Admin\ access Root\ access Bundles dylibs Apps Font\ issues Inserted\ dylibs Firewall Proxies DNS TCP/IP Wi-Fi Profiles Root\ crontab User\ crontab 'Global login items' 'User login items' Spotlight Memory Listeners Widgets Parental\ Controls Prefetching SATA Descriptors App\ extensions Lockfiles Memory\ pressure SMC Shutdowns );N3=${#l[@]};for i in 0 1 2;do l[N3+i]=${p[5+i]};done;N4=${#l[@]};for j in 0 1;do l[N4+j]="Current ${p[29+j]}stream data";done;A0() { id -G|grep -qw 80;v[1]=$?;((v[1]==0))&&sudo true;v[2]=$?;v[3]=`date +%s`;clear >&-;date '+Start time: %T %D%n';};for i in 0 1;do eval ' A'$((1+i))'() { v=` eval "${c1[$1]} ${c2[$2]}"|'${c1[30+i]}' "${s[$3]}" `;[[ "$v" ]];};A'$((3+i))'() { v=` while read i;do [[ "$i" ]]&&eval "${c1[$1]} ${c2[$2]}" \"$i\"|'${c1[30+i]}' "${s[$3]}";done<<<"${v[$4]}" `;[[ "$v" ]];};A'$((5+i))'() { v=` while read i;do '${c1[30+i]}' "${s[$1]}" "$i";done<<<"${v[$2]}" `;[[ "$v" ]];};A'$((7+i))'() { v=` eval sudo "${c1[$1]} ${c2[$2]}"|'${c1[30+i]}' "${s[$3]}" `;[[ "$v" ]];};';done;A9(){ v=$((`date +%s`-v[3]));};B2(){ v[$1]="$v";};for i in 0 1;do eval ' B'$i'() { v=;((v['$((i+1))']==0))||{ v=No;false;};};B'$((3+i))'() { v[$2]=`'${c1[30+i]}' "${s[$3]}"<<<"${v[$1]}"`;} ';done;B5(){ v[$1]="${v[$1]}"$'\n'"${v[$2]}";};B6() { v=` paste -d: <(printf "${v[$1]}") <(printf "${v[$2]}")|awk -F: ' {printf("'"${f[$3]}"'",$1,$2)} ' `;};B7(){ v=`grep -Fv "${v[$1]}"<<<"$v"`;};C0() { [[ "$v" ]]&&sed -E "$s"<<<"$v";};C1() { [[ "$v" ]]&&printf "${f[$1]}" "${l[$2]}" "$v"|sed -E "$s";};C2() { v=`echo $v`;[[ "$v" != 0 ]]&&C1 0 $1;};C3() { v=`sed -E "${s[63]}"<<<"$v"`&&C1 1 $1;};for i in 1 2 7 8;do for j in 0 2 3;do eval D$i$j'(){ A'$i' $1 $2 $3; C'$j' $4;};';done;done;{ A0;D20 0 $((N1+1)) 2;D10 0 $N1 1;B0;C2 27;B0&&! B1&&C2 28;D12 15 37 25 8;A1 0 $((N1+2)) 3;C0;D13 0 $((N1+3)) 4 3;D23 0 $((N1+4)) 5 4;D13 0 $((N1+9)) 59 50;for i in 0 1 2;do D13 0 $((N1+5+i)) 6 $((N3+i));done;D13 1 10 7 9;D13 1 11 8 10;B1&&D73 19 53 67 55;D22 2 12 9 11;D12 3 13 10 12;D23 4 19 44 13;D23 5 54 12 56;D23 5 14 12 14;D22 6 36 13 15;D22 20 52 66 54;D22 7 37 14 16;D23 8 15 38 17;D22 9 16 16 18;B1&&{ D82 35 49 61 51;D82 11 17 17 20;for i in 0 1;do D82 28 $((N2+i)) 45 $((N4+i));done;};D22 12 44 54 45;D22 12 39 15 21;A1 13 40 18;B2 4;B3 4 0 19;A3 14 6 32 0;B4 0 5 11;A1 17 41 20;B7 5;C3 22;B4 4 6 21;A3 14 7 32 6;B4 0 7 11;B3 4 0 22;A3 14 6 32 0;B4 0 8 11;B5 7 8;B1&&{ A8 18 26 23;B7 7;C3 23;};A2 18 26 23;B7 7;C3 24;D13 4 21 24 26;B4 4 12 26;B3 4 13 27;A1 4 22 29;B7 12;B2 14;A4 14 6 52 14;B2 15;B6 14 15 4;B3 0 0 30;C3 29;A1 4 23 27;B7 13;C3 30;B3 4 0 65;A3 14 6 32 0;B4 0 16 11;A1 26 50 64;B7 16;C3 52;D13 24 24 32 31;D13 25 37 32 33;A2 23 18 28;B2 16;A2 16 25 33;B7 16;B3 0 0 34;B2 21;A6 47 21&&C0;B1&&{ D73 21 0 32 19;D73 10 42 32 40;D82 29 35 46 39;};D23 14 1 62 42;D12 34 43 53 44;D12 22 20 32 25;D22 0 $((N1+8)) 51 32;D13 4 8 41 6;D12 21 28 35 34;D13 27 29 36 35;A2 27 32 39&&{ B2 19;A2 33 33 40;B2 20;B6 19 20 3;};C2 36;D23 33 34 42 37;B1&&D83 35 45 55 46;D23 32 31 43 38;D12 36 47 32 48;D13 10 42 32 41;D13 37 2 48 43;D13 4 5 32 1;D13 4 3 60 5;D12 21 48 49 49;B3 4 22 57;A1 21 46 56;B7 22;B3 0 0 58;C3 47;D22 4 4 50 0;D12 4 51 32 53;D23 22 9 37 7;A9;C2 2;} 2>/dev/null|pbcopy;exit 2>&-
    Copy the selected text to the Clipboard by pressing the key combination command-C.
    8. Launch the built-in Terminal application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Terminal in the icon grid.
    Click anywhere in the Terminal window and paste by pressing command-V. The text you pasted should vanish immediately. If it doesn't, press the return key.
    9. If you see an error message in the Terminal window such as "Syntax error" or "Event not found," enter
    exec bash
    and press return. Then paste the script again.
    10. If you're logged in as an administrator, you'll be prompted for your login password. Nothing will be displayed when you type it. You will not see the usual dots in place of typed characters. Make sure caps lock is off. Type carefully and then press return. You may get a one-time warning to be careful. If you make three failed attempts to enter the password, the test will run anyway, but it will produce less information. In most cases, the difference is not important. If you don't know the password, or if you prefer not to enter it, press the key combination control-C or just press return  three times at the password prompt. Again, the script will still run.
    If you're not logged in as an administrator, you won't be prompted for a password. The test will still run. It just won't do anything that requires administrator privileges.
    11. The test may take a few minutes to run, depending on how many files you have and the speed of the computer. A computer that's abnormally slow may take longer to run the test. While it's running, there will be nothing in the Terminal window and no indication of progress. Wait for the line
    [Process completed]
    to appear. If you don't see it within half an hour or so, the test probably won't complete in a reasonable time. In that case, close the Terminal window and report what happened. No harm will be done.
    12. When the test is complete, quit Terminal. The results will have been copied to the Clipboard automatically. They are not shown in the Terminal window. Please don't copy anything from there. All you have to do is start a reply to this comment and then paste by pressing command-V again.
    At the top of the results, there will be a line that begins with the words "Start time." If you don't see that, but instead see a mass of gibberish, you didn't wait for the "Process completed" message to appear in the Terminal window. Please wait for it and try again.
    If any private information, such as your name or email address, appears in the results, anonymize it before posting. Usually that won't be necessary.
    13. When you post the results, you might see an error message on the web page: "You have included content in your post that is not permitted," or "You are not authorized to post." That's a bug in the forum software. Please post the test results on Pastebin, then post a link here to the page you created.
    14. This is a public forum, and others may give you advice based on the results of the test. They speak only for themselves, and I don't necessarily agree with them.
    Copyright © 2014 by Linc Davis. As the sole author of this work, I reserve all rights to it except as provided in the Use Agreement for the Apple Support Communities website ("ASC"). Readers of ASC may copy it for their own personal use. Neither the whole nor any part may be redistributed.

  • Any workarounds for the X11 apps segmentation faults on intel with 10.4.8 ?

    Hi,
    We've an X11 application, compiled for PPC, which runs fine with a G5 iMac on 10.4.8. However, it crashes with a segmentation fault on a MacBook Pro with 10.4.8 (running through Rosetta).
    Searching the web, we found that this seems to be a widespread problem for X11 apps running on Intel Macs with 10.4.8.
    Has this been submitted as an important bug to Apple?
    Are there any workarounds for it?
    Is the problem specific to PPC-only builds, or does it also happen with Universal builds?
    Thank you for any hints you could give about this,
    cesar
      Mac OS X (10.4.8)  

    A powerpc-binary program running under Rosetta can only load powerpc-binary modules...can't cross in and out of emulation within a single process. Perhaps your program is trying to load a module from X11 that is present as an intel-only binary? Rosetta is certainly no future-looking cure-all, just a stop-gap to allow one to keep using older stuff, and it is kinda fragile sometimes. If your target audience is both powerpc and intel machines, compile as a universal binary so it's native for everyone.

  • I don't want to stay with iOS 7 any more, i can't tolerate it to being very slow and to hand while playing games, it doesn't run properly, i have no games in my phone right now becouse of that bug, could i downgrade my ios of iphone 4s? Please help thanx

    I don't want to stay with iOS 7 any more, i can't tolerate it to being very slow and to hand while playing games, it doesn't run properly, i have no games in my phone right now becouse of that bug, could i downgrade my ios of iphone 4s? Please help thanx

    That is HANG sorry miss type

  • I upgraded my 3rd gen iTouch to iOS 5.1.1 and now its speed to repond is slower and the battery goes flat quicker than before the upgrade. Skype, Sky iCloud and other apps are turned off (I think). Has anybody else suffered with this? Any ideas?

    I upgraded my 3rd gen iTouch to iOS 5.1.1 and now its speed to repond is slower and the battery goes flat quicker than before the upgrade. Skype, Sky iCloud and other apps are turned off (I think). Has anybody else suffered with this? Any ideas?

    Purplehiddledog wrote:
    I do backup with iCloud.  I can't wait until the new iMac is available so that I can once again have my files in more than 1 location without needing to rely solely on the cloud. 
    I also rely on iTunes and my MacBook and Time Machine as well as backing up to iCloud. I know many users know have gone totally PC free, but I chose to use iCloud merely as my third backup.
    I assume that the restore would result in my ability to open Pages and Numbers and fix the problem with deleting apps, but this would also mean that if my Numbers documents still exist solely within the app and are just not on iCloud for some reason that they would be gone forever.  Is that right?
    In a word, yes. In a little more detail.... When you restore from an iCloud backup, you must erase the device and start all over again. There is no other way to access the backup in iCloud without erasing the device. Consequently, you are starting all over again. Therefore, it would also be my assumption that Pages and Numbers will work again and that the deleting apps issues would be fixed as well.
    If the documents are not in the backup, and you do not have a backup elsewhere, the documents could be gone forever.

  • Any workaround to make OCCI works with stlport?

    Dear all,
    after read num of threads in the forum, I found myself in a popular problem of OCCI with stlport, is there any workaround for it (except: fallback to use OCI or drop stlport)?
    any 3rd party library or .. anything suggested?
    Thank you very very much
    Reggie

    For Solaris or Linux?
    Thanks,
    Shankar

  • Saving files is very slow!!!

    Since I installed (updated) from CS5 to CS5.1, saving files is very slow. It takes like 4 minutes save a 2048 X 2048 png file which used to take seconds in CS5.
    I am not sure what changed... I completely uninstalled all versions of Photoshop. Re-downloaded from the website. Deleted my user preferences and the problem remains.
    Why is saving so slow all of a sudden?
    Using Windows 7 - 64 bit

    Hm, that's kind of alarming.  Is it happening with all files or just PNG.
    If every file does that, it could be a possible indication that your disk is going bad...
    Click Start and type view events into the search box. 
    When View event logs comes up, click it.
    Navigate down into Windows Logs > System and see if there are any Error events there that indicate problems with your disk.
    If this isn't the problem, it's possible that Photoshop is having to wait for a disk to spin up to be able to access it.  Do you see the problem occur when you save again right away?  Are you using an external drive for either file storage or as a scratch disk in Photoshop?
    Lastly, you may have a stored printer or drive connection to a location on your network that does not exist now (or is not responding) and that has to time out before completing the operation.  Have you changed anything in your network lately?
    -Noel

  • Premiere pro 5.5 stops working when playing a sequence, saving a project or closing,any ideas why?

    I can open a project, import files or other projects, but when I want to play the sequence the program stops working and closes. When I try to save the project or close the program I get a "software not responding" message.
    I hope someone can help me with this as I cannot work on any projects.
    thanks.

    Hi john,
    thanks for taking the time to help me. I have updated the software and rendered the files and now I am able to play them, but still neither the sequence nor the clip play/show on the corresponding screens, I can only hear the audio file. I also continue having problems when saving the project, the software stops working and I get the "non responding" error from microsoft.
    As you suggested, and I have to say I am pretty much a dummy with the codecs and alike, I installed the mediainfo and run one of the files.
    This is the info that appears on the screen
    I am not getting any error messages from Premiere, so I am kind of stock. If you need other info let me know.
    Thanks for your help and patience.
    Arantza
    Date: Mon, 23 Apr 2012 09:12:15 -0600
    From: [email protected]
    To: [email protected]
    Subject: premiere pro 5.5 stops working when playing a sequence, saving a project or closing,any ideas why?
        Re: premiere pro 5.5 stops working when playing a sequence, saving a project or closing,any ideas why?
        created by John T Smith in Premiere Pro CS5, CS5.5, & CS6 - View the full discussion
    Read Bill Hunt on a file type as WRAPPER http://forums.adobe.com/thread/440037What is a CODEC... a Primer http://forums.adobe.com/thread/546811What CODEC is INSIDE that file? http://forums.adobe.com/thread/440037.Report back with the codec details of your file, use the programs below... a screen shot works well to SHOW people what you are doing.For PC http://www.headbands.com/gspot/ or http://mediainfo.sourceforge.net/enFor Mac http://mediainspector.massanti.com/.http://blogs.adobe.com/premiereprotraining/2011/02/red -yellow-and-gree n-render-bars.html.If you have a red line over the timeline after importing a video and before adding any effects... your project is wrong for your video... read above about codecs.Once you know exactly what it is you are editing, report back with that information... and your project setting, and if there is a red line above the video in the timeline, which indicates a mismatch between video and project.H.264 will NOT work inside an AVI http://forums.adobe.com/thread/854115.More information needed for someone to help... click these links and provided the requested information-http://forums.adobe.com/message/4200840-http://forums.adobe.com/thread/416679.For CS5 and later, the easy way to insure that your video and your project matchSee 2nd post for picture of NEW ITEM process http://forums.adobe.com/thread/872666
         Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/4354727#4354727
         To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/4354727#4354727. In the Actions box on the right, click the Stop Email Notifications link.
         Start a new discussion in Premiere Pro CS5, CS5.5, & CS6 by email or at Adobe Forums
      For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746.

  • AVI with ac3 import problem

    hi
    sorry for my bad english
    0.avi opens in adobe premiere pro cs6 without any problem.
    mediainfo result for 0.avi:
    General
    Complete name                            : C:\Users\User\Desktop\****\0.avi
    Format                                   : AVI
    Format/Info                              : Audio Video Interleave
    File size                                : 232 MiB
    Duration                                 : 18mn 52s
    Overall bit rate                         : 1 722 Kbps
    Video
    ID                                       : 0
    Format                                   : MPEG-4 Visual
    Format profile                           : Advanced Simple@L5
    Format settings, BVOP                    : 1
    Format settings, QPel                    : No
    Format settings, GMC                     : No warppoints
    Format settings, Matrix                  : Custom
    Codec ID                                 : XVID
    Codec ID/Hint                            : XviD
    Duration                                 : 18mn 52s
    Bit rate                                 : 1 261 Kbps
    Width                                    : 720 pixels
    Height                                   : 304 pixels
    Display aspect ratio                     : 2.35:1
    Frame rate                               : 23.976 fps
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Scan type                                : Progressive
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 0.240
    Stream size                              : 170 MiB (73%)
    Writing library                          : XviD 65
    Audio
    ID                                       : 1
    Format                                   : AC-3
    Format/Info                              : Audio Coding 3
    Mode extension                           : CM (complete main)
    Format settings, Endianness              : Big
    Codec ID                                 : 2000
    Duration                                 : 18mn 52s
    Bit rate mode                            : Constant
    Bit rate                                 : 448 Kbps
    Channel(s)                               : 6 channels
    Channel positions                        : Front: L C R, Side: L R, LFE
    Sampling rate                            : 48.0 KHz
    Bit depth                                : 16 bits
    Compression mode                         : Lossy
    Stream size                              : 60.5 MiB (26%)
    Alignment                                : Aligned on interleaves
    Interleave, duration                     : 32 ms (0.77 video frame
    but when i import 1.avi it gives error:
    the file contains an unsupported audio format.
    mediainfo result for 1.avi:
    General
    Complete name                            : C:\Users\User\Desktop\****\1.avi
    Format                                   : AVI
    Format/Info                              : Audio Video Interleave
    File size                                : 67.2 MiB
    Duration                                 : 4mn 27s
    Overall bit rate                         : 2 106 Kbps
    Video
    ID                                       : 0
    Format                                   : MPEG-4 Visual
    Format profile                           : Advanced Simple@L5
    Format settings, BVOP                    : 1
    Format settings, QPel                    : No
    Format settings, GMC                     : No warppoints
    Format settings, Matrix                  : Custom
    Codec ID                                 : XVID
    Codec ID/Hint                            : XviD
    Duration                                 : 4mn 27s
    Bit rate                                 : 1 500 Kbps
    Width                                    : 704 pixels
    Height                                   : 384 pixels
    Display aspect ratio                     : 1.85:1
    Frame rate                               : 23.976 fps
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Scan type                                : Progressive
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 0.231
    Stream size                              : 47.9 MiB (71%)
    Writing library                          : XviD 64
    Audio #1
    ID                                       : 1
    Format                                   : AC-3
    Format/Info                              : Audio Coding 3
    Mode extension                           : CM (complete main)
    Format settings, Endianness              : Big
    Codec ID                                 : 2000
    Duration                                 : 4mn 27s
    Bit rate mode                            : Constant
    Bit rate                                 : 384 Kbps
    Channel(s)                               : 6 channels
    Channel positions                        : Front: L C R, Side: L R, LFE
    Sampling rate                            : 48.0 KHz
    Bit depth                                : 16 bits
    Compression mode                         : Lossy
    Delay relative to video                  : 32ms
    Stream size                              : 12.3 MiB (18%)
    Alignment                                : Split accross interleaves
    Interleave, duration                     : 32 ms (0.77 video frame)
    Audio #2
    ID                                       : 2
    Format                                   : AC-3
    Format/Info                              : Audio Coding 3
    Mode extension                           : CM (complete main)
    Format settings, Endianness              : Big
    Codec ID                                 : 2000
    Duration                                 : 4mn 27s
    Bit rate mode                            : Constant
    Bit rate                                 : 192 Kbps
    Channel(s)                               : 2 channels
    Channel positions                        : Front: L R
    Sampling rate                            : 48.0 KHz
    Bit depth                                : 16 bits
    Compression mode                         : Lossy
    Stream size                              : 6.13 MiB (9%)
    Alignment                                : Aligned on interleaves
    Interleave, duration                     : 32 ms (0.77 video frame)
    and when i extract video and ac3 file from 1.avi with avidemux then i can import them separately. but after importing audio and video in timeline audio length not same with video.
    the length difference in the image:

    Hi,
    I don't have GraphicConverter and since it is shareware and money is tight right now, I tried to find a freeware image converter on the internet for the Mac. I didn't. I remembered that I have Photoshop Essentials. It came with my Canon scanner. I installed it and looked to see if it had a converter of some type in it. I saw that you can import a file, work with it and then save it to what you want. I thought that I had already done that with the Nikon files. Anyway, I tested it. I imported one of the Nikon images into it and saved it as a jpeg- even though it appeared to be a jpeg already. Bingo! It worked. It imported into my video editing program. I selected two other files from the Nikon shots and did the same thing. I change the name of the picture and then save it as a jpeg in Photoshop Essentials 2. The two files imported into my video editing program. I then went to the two original Nikon files that I had imported into Photoshop Essentials 2 and changed the names of them- leaving the jpeg extension on to see if they would import, they did not. So, as you said, there must by some kind of Metadata with those files. Bringing them into Photoshop Essentials 2 and saving them as jpegs fixed it. Because of what happened, I just went through my approx. 4,000 pictures and selected about 1,400 again for a new family DVD. I created folder and exported 1,446 jpeg pictures into it. Then I opened by video editing program and imported the folder. All 1,446 pictures came in. I didn't try it with FCE and iMovie, since I the program I regularly use is Adobe Premiere. I may try it later, but I am pretty confident that if the pictures can be imported into Adobe Premiere, they can also be imported into FCE and iMovie(unless there is a number limit.)
    All this has taken place over several days. I am glad that it is figured out.
    Thank you for the help.

  • Captuer image with overlay view

    Hi.
    i m on this for last 2 or 3 days.
    i have a UIImagePicker and set its source type to UIImagePickerControllerSourceTypeCamera. and i have an overlay view on it. Now i want to capture image with overlay view.
    i m not using camera controls picker.showsCameraControls = FALSE; and have my custom toolbar with camera button. code i tried is
    //btnCameraTaped
    -(void)btnCameraTaped:(id)sender
    CGRect contextRect = CGRectMake(0, 50, 320, 430);
    UIGraphicsBeginImageContext(contextRect.size);
    [picker.view.layer renderInContext:UIGraphicsGetCurrentContext()];
    viewImage = UIGraphicsGetImageFromCurrentImageContext();
    UIGraphicsEndImageContext();
    //above code save overlay view in viewImage
    [picker takePicture];
    - (void)imagePickerController:(UIImagePickerController *)picker1 didFinishPickingMediaWithInfo:(NSDictionary *)info {
    UIImage *camImage = [info objectForKey:@"UIImagePickerControllerOriginalImage"];
    //trying to merge viewImage and camImage i don't know what it is doing i found it on stackoverflow
    UIGraphicsBeginImageContext(camImage.size);
    [camImage drawAtPoint:CGPointMake(0,0)]; //crash on this line
    [viewImage drawAtPoint:CGPointMake(0,0)];
    UIImage *newImage = UIGraphicsGetImageFromCurrentImageContext();
    UIGraphicsEndImageContext();
    //saving it in photo library
    UIImageWriteToSavedPhotosAlbum(newImage, self, @selector(image:didFinishSavingWithError:contextInfo:), nil);
    but code crashes on [camImage drawAtPoint:CGPointMake(0,0)];
    if any one have any idea what i m doing wrong. or is there any better way to do this.
    Usman

    finally found the solution from http://trandangkhoa.blogspot.com/2009/07/iphone-os-drawing-image-and-stupid.html
    - (void)imagePickerController:(UIImagePickerController *)picker1 didFinishPickingMediaWithInfo:(NSDictionary *)info {
    UIImage *camImage = [info objectForKey:@"UIImagePickerControllerOriginalImage"];
    int width = camImage.size.width;
    int height = camImage.size.height;
    CGSize size = CGSizeMake(width, height);
    //create the rect zone that we draw from the image
    CGRect camImageRect;
    if(camImage.imageOrientation==UIImageOrientationUp
    || camImage.imageOrientation==UIImageOrientationDown)
    camImageRect = CGRectMake(0, 0, width, height);
    else
    camImageRect = CGRectMake(0, 0, height, width);
    UIGraphicsBeginImageContext(size);
    CGContextRef context = UIGraphicsGetCurrentContext();
    //Save current status of graphics context
    CGContextSaveGState(context);
    //Do stupid stuff to draw the image correctly
    CGContextTranslateCTM(context, 0, height);
    CGContextScaleCTM(context, 1.0, -1.0);
    if(camImage.imageOrientation==UIImageOrientationLeft)
    CGContextRotateCTM(context, M_PI / 2);
    CGContextTranslateCTM(context, 0, -width);
    else if(camImage.imageOrientation==UIImageOrientationRight)
    CGContextRotateCTM(context, - M_PI / 2);
    CGContextTranslateCTM(context, -height, 0);
    else if(camImage.imageOrientation==UIImageOrientationUp)
    else if(camImage.imageOrientation==UIImageOrientationDown)
    CGContextTranslateCTM(context, width, height);
    CGContextRotateCTM(context, M_PI);
    CGContextDrawImage(context, camImageRect, camImage.CGImage);
    //After drawing the image, roll back all transformation by restoring the
    //old context
    CGContextRestoreGState(context);
    //For viewImage
    CGRect viewImageRect;
    if(viewImage.imageOrientation==UIImageOrientationUp
    || viewImage.imageOrientation==UIImageOrientationDown)
    viewImageRect = CGRectMake(0, 0, width, height);
    else
    viewImageRect = CGRectMake(0, 0, height, width);
    CGContextSaveGState(context);
    CGContextTranslateCTM(context, 0, height);
    CGContextScaleCTM(context, 1.0, -1.0);
    if(viewImage.imageOrientation==UIImageOrientationLeft)
    CGContextRotateCTM(context, M_PI / 2);
    CGContextTranslateCTM(context, 0, -width);
    else if(viewImage.imageOrientation==UIImageOrientationRight)
    CGContextRotateCTM(context, - M_PI / 2);
    CGContextTranslateCTM(context, -height, 0);
    else if(viewImage.imageOrientation==UIImageOrientationUp)
    else if(viewImage.imageOrientation==UIImageOrientationDown)
    CGContextTranslateCTM(context, width, height);
    CGContextRotateCTM(context, M_PI);
    CGContextSetAlpha (context,0.5);
    CGContextDrawImage(context, viewImageRect, viewImage.CGImage);
    //After drawing the image, roll back all transformation by restoring the
    //old context
    CGContextRestoreGState(context);
    //DO OTHER EFFECTS HERE
    //get the image from the graphic context
    UIImage *outputImage = UIGraphicsGetImageFromCurrentImageContext();
    UIImageWriteToSavedPhotosAlbum(outputImage, self, @selector(image:didFinishSavingWithError:contextInfo:), nil);
    //commit all drawing effects
    UIGraphicsEndImageContext();
    Usman

  • ORACLE treats empty Strings as NULL, Any workaround?

    Hi,
    ORACLE treats empty Strings as NULL.
    I am writing, rather modifying Java code to make it work with both SQLServer and Oracle. Since our code is already working for SQLServer, now I have the problem in porting to Oracle wherever I have empty strings. I used to insert empty strings into coulumns in SQLServers, the same SQLs give errors in SQL Server.
    Any workaround on the DB end or in JDBC for this?
    Thanks in advance,
    Suresh
    [email protected]

    jschell wrote:
    nichele wrote:
    jwenting wrote:
    If NULL really is different in your context from an empty string you're going to have to define some sequence of characters as indicating an empty string.yes, this is what i need to implement.Sounds like a flawed design then.
    I'm wondering what's the best approach in order to avoid to change all my application isolating this behavior somewhere (wrapping the jdbc driver for instance).That doesn't make much sense to me. You should already have a database layer. You change the database layer. If you don't have a database layer then that means you have another design flaw. And in that case I would really not be the one that needs to maintain that code base.I thought a bit about the value of your answer...but i didn't find it ....sorry but i don't like who replies on forum just to say bad design/bad choice etc...if you have any kind of suggestion you are welcome, otherwise you can spend your time in doing something else instead of reply to this thread.

  • I am having a problem with very slow start up after expanding RAM on my 2009 Mac Pro.

    I am having a problem with very slow start up after expanding RAM on my 2009 Mac Pro (8 Core 2.93GHz). When I run the Mac Pro with 2 x 2Gb RAM it takes 4 seconds before the gray screen, chime and spinning wheel appear.However when I expand the RAM to 20GB the grey screen and chimes appear after a long 20+ second black screen.
    The RAM modules are paored  2 x 4GB Crucial CT51272BA1339.M18FMR and  6 x 2GB SAMSUNG M391B5673FH0-CH9, all DDR3 ECC.
    Reading articles on the internet, I thought it may be damaged RAM modules, but I have completed memtest and all are okay. I have tried changing the pairs around and if I use any paired 2 modules the Mac Pro starts normally, only when I try running more than 2 modules the delayed start up happens. (black screen 20 Seconds)
    I also have tried PRAM and SMU resets after changing the RAM setups, and the issues always occurs when I have more than 2 modules. As you can see I have 6 SAMSUNG modules and even with identical modules the issue happens, when increasing the RAM to more than 2 modules.
    The Mac Pro runs fine after the start up screen and can see all the modules, but has anyone else come across this issue, or have any ideas as to why my Mac Pro is taking 20 seconds to start up with 20 GB RAM?

    Hi there. Thanks for your comments.
    I have tried all the different combinations of RAM setup, and as stated in my initial topic, the Mac Pro boot up time only slows when I have more that 2 modules. Where I place these does not seem to make a difference.
    I have taken the Mac Pro to an Apple Reseller technician yesterday and they where not able to find any RAM errors. Apparently the boot up time is within Apple's acceptable parameters for this set up.
    Could anyone that is running a Mac Pro 2009 with more that 4 modules of RAM, please let me know if the boot up time is normal. ( the time it takes from pressing the power button to seeing the gray screen around 16 - 20 seconds)
    Or is anyone else having the same issues?
    thanks for your responce

  • Zen Vision M Firmware Problem!!! Can't deal with this thing any more...

    Can't deal with this thing any more...3 Hello friends I'm new in the forum
    Well as the title mentions, I'm about to throw this thing oute of the window!!!
    It's a 30 GB Zen Vision M, I own it ,5 years now...
    I have read all the relevant posts in the forum about this player, I tried my best, nothing really worked.....
    So now I have a Zen which only boots in the recovery mode!!
    I have Cleaned it Up, Formated it, and tried to reload its firmware BUT when I connect it and try to reload it, in the end it always says Firmware Upgrade Failed!!Really can't understand it!!!!!
    I've communicated with Creative, i wasn't at all satisfied with their responses... I think what they're trying to do is to avoid me, and earn some time with really useless suggestions which I had already told them won't work!!!So in the end they wanted me to send my Zen in Italy and pay more than 100 Euros for what an ,5 year old mp3 player?No I prefer buying a new Cowon with that amount of money!!!
    Anyways I'm pretty mad now, so I'll move to the subject..
    I have Service Pack 3 Windows XP in my computer, and I did roll back on the Media Player 0 from the I had, using the instructions from a previous post. The truth is that it rolled back with less steps than it showed, and I say that because it mentions in a step that in the add-remove programms, in the Windows XP-Software Updates section, I should find a Windows Media player thing which really doesnt exist and I suspect it's the Service Pack 3 because I have done the same in a SP2 and worked exactly as the steps said..Anyway the fact is I have Windows Media Player 0 now!!!
    Please someone tell why can't I upgrade my firmware... I can't deal with this anymore!!!!

    KRe: Zen Vision M Firmware Problem!!! Can't deal with this thing any more..._
    menios wrote:
    So you say that I actually have the Windows Media Player 0, because my Zen is being recognised..
    I have rebooted it several times but its just the same thing...it shows firmware problem!!
    Why isn't this player working?I've seen many people, not only from here, who have the same exact problem and they gave up on their mp3... I dont have this kind of luxury to buy a new one!!I don't know whether Creative has put on this a "time bomb" or is just faulty, but I really wish it could be saved..
    I'm saying it is WMP0 because the firmware file sees the player. The computer can recognize it but with WMP components that firmware file would be grayed-out..So when you reloaded the firmware did you choose "reload firmware" Before you connected it's?(That is what erases the firmware prior to uploading the firmware. If you did not do that it could cause it to fail.Do these ste
    ps.
    Open the firmware file,On the player format>cleanup>choose reload firmware, then connect & run the firmware file.

Maybe you are looking for

  • Satellite Pro L40 (PSL43E) Wi-Fi intermittant

    Well I am fed up with this laptop and its intermittent Wi-Fi connection. You just dont know from powering up if it wants to work or not, and when it doesnt, it can be an absolute nightmare getting it to detect the router. The adaptor properties alway

  • BackUp over WAN (with MobileMe)

    Hello, I can remotely connect to my TC (when on the road) using my MobileMe account and "Back to my Mac". I can see it on finder, connect to it, read/write to files all is well. But I just can't do any backup with Time Machine. It says the backup dis

  • Re: Transfer of sales quantity to COPA

    Dear CO guys I have activated CO based COPA and i am transferring sales orders to PA using Record A. I wish to transfer sales quantity in the sales order to COPA and unfortunately this particular field is not getting transferred. But i could transfer

  • 6300 V5.50

    Hi all i just updated my phone to the new firmware and WOW what a difference the sound quality has improved, the # key works to change to silent.It changed the font size to large in contacts but that is easy to fix thankyou Nokia.

  • How to Get As is and As was data using Hierarchies.

    Hi Experts, I have scenario,  I want to report sales by the Sales Organization Hierarchy.. A- B- ORG1 -( 01/2010 - 05/2010)   -    100 After 05/2010 my ORG1 has been changed from B to C then my Hierarchy looks like this A-C- ORG1 - ( 06/2010 to 12/99